Print this page
5218 posix definition of NULL
correct unistd.h and iso/stddef_iso.h
update gate source affected


 936                                         DBG_F(2, (stdout, "%c\n", buf[i]));
 937                                 }
 938                                 buf[i] = '\0'; str++;
 939                                 DBG(2, ("buf = %s\n", buf));
 940 
 941                                 /* ACTIVE=3,ATTN=2,POWER=1,FAULT=0 */
 942                                 if (strcmp(buf, led_strs[POWER]) == 0)
 943                                         led = PCIEHPC_PROP_LED_POWER;
 944                                 else if (strcmp(buf, led_strs[FAULT]) == 0)
 945                                         led = PCIEHPC_PROP_LED_FAULT;
 946                                 else if (strcmp(buf, led_strs[ATTN]) == 0)
 947                                         led = PCIEHPC_PROP_LED_ATTN;
 948                                 else if (strcmp(buf, led_strs[ACTIVE]) == 0)
 949                                         led = PCIEHPC_PROP_LED_ACTIVE;
 950                                 else return (CFGA_INVAL);
 951 
 952                                 len = strlen(func_strs[MODE]);
 953                                 if ((strncmp(str, func_strs[MODE], len) == 0) &&
 954                                     (*(str+(len)) == '=')) {
 955                                         for (str = (str+(++len)), i = 0;
 956                                             *str != NULL; i++, str++) {
 957                                                 buf[i] = *str;
 958                                         }
 959                                 }
 960                                 buf[i] = '\0';
 961                                 DBG(2, ("buf_mode= %s\n", buf));
 962 
 963                                 /* ON = 1, OFF = 0 */
 964                                 if (strcmp(buf, mode_strs[ON]) == 0)
 965                                         mode = PCIEHPC_PROP_VALUE_ON;
 966                                 else if (strcmp(buf, mode_strs[OFF]) == 0)
 967                                         mode = PCIEHPC_PROP_VALUE_OFF;
 968                                 else if (strcmp(buf, mode_strs[BLINK]) == 0)
 969                                         mode = PCIEHPC_PROP_VALUE_BLINK;
 970                                 else return (CFGA_INVAL);
 971 
 972                                 /* sendin  */
 973                                 memset(buf, 0, sizeof (buf));
 974                                 snprintf(buf, sizeof (buf), "%s=%s",
 975                                     led, mode);
 976                                 buf[MAXNAMELEN - 1] = '\0';




 936                                         DBG_F(2, (stdout, "%c\n", buf[i]));
 937                                 }
 938                                 buf[i] = '\0'; str++;
 939                                 DBG(2, ("buf = %s\n", buf));
 940 
 941                                 /* ACTIVE=3,ATTN=2,POWER=1,FAULT=0 */
 942                                 if (strcmp(buf, led_strs[POWER]) == 0)
 943                                         led = PCIEHPC_PROP_LED_POWER;
 944                                 else if (strcmp(buf, led_strs[FAULT]) == 0)
 945                                         led = PCIEHPC_PROP_LED_FAULT;
 946                                 else if (strcmp(buf, led_strs[ATTN]) == 0)
 947                                         led = PCIEHPC_PROP_LED_ATTN;
 948                                 else if (strcmp(buf, led_strs[ACTIVE]) == 0)
 949                                         led = PCIEHPC_PROP_LED_ACTIVE;
 950                                 else return (CFGA_INVAL);
 951 
 952                                 len = strlen(func_strs[MODE]);
 953                                 if ((strncmp(str, func_strs[MODE], len) == 0) &&
 954                                     (*(str+(len)) == '=')) {
 955                                         for (str = (str+(++len)), i = 0;
 956                                             *str != '\0'; i++, str++) {
 957                                                 buf[i] = *str;
 958                                         }
 959                                 }
 960                                 buf[i] = '\0';
 961                                 DBG(2, ("buf_mode= %s\n", buf));
 962 
 963                                 /* ON = 1, OFF = 0 */
 964                                 if (strcmp(buf, mode_strs[ON]) == 0)
 965                                         mode = PCIEHPC_PROP_VALUE_ON;
 966                                 else if (strcmp(buf, mode_strs[OFF]) == 0)
 967                                         mode = PCIEHPC_PROP_VALUE_OFF;
 968                                 else if (strcmp(buf, mode_strs[BLINK]) == 0)
 969                                         mode = PCIEHPC_PROP_VALUE_BLINK;
 970                                 else return (CFGA_INVAL);
 971 
 972                                 /* sendin  */
 973                                 memset(buf, 0, sizeof (buf));
 974                                 snprintf(buf, sizeof (buf), "%s=%s",
 975                                     led, mode);
 976                                 buf[MAXNAMELEN - 1] = '\0';