Print this page
Code review comments from jeffpc

Split Close
Expand all
Collapse all
          --- old/usr/src/cmd/sgs/libconv/common/corenote.c
          +++ new/usr/src/cmd/sgs/libconv/common/corenote.c
↓ open down ↓ 2613 lines elided ↑ open up ↑
2614 2614          /*
2615 2615           * The values are initialized later, based on position in this array
2616 2616           */
2617 2617          static Val_desc vda[] = {
2618 2618                  { 0, MSG_ASLR },
2619 2619                  { 0, MSG_FORBIDNULLMAP },
2620 2620                  { 0, MSG_NOEXECSTACK },
2621 2621                  { 0, 0 }
2622 2622          };
2623 2623          static CONV_EXPN_FIELD_ARG conv_arg = {
2624      -            NULL, sizeof (secflags_buf->buf) };
     2624 +            NULL, sizeof (secflags_buf->buf)
     2625 +        };
2625 2626          int i;
2626 2627  
2627      -        for (i = 0; vda[i].v_msg != 0; i++) {
     2628 +        for (i = 0; vda[i].v_msg != 0; i++)
2628 2629                  vda[i].v_val = secflag_to_bit(i);
2629      -        }
2630 2630  
2631 2631          if (flags == 0)
2632 2632                  return (MSG_ORIG(MSG_GBL_ZERO));
2633 2633  
2634 2634          conv_arg.buf = secflags_buf->buf;
2635 2635          conv_arg.oflags = conv_arg.rflags = flags;
2636 2636          (void) conv_expn_field(&conv_arg, vda, fmt_flags);
2637 2637  
2638 2638          return ((const char *)secflags_buf->buf);
2639 2639  }
    
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX