Print this page
5910 libnisdb won't build with modern GCC

*** 18,33 **** * information: Portions Copyright [yyyy] [name of copyright owner] * * CDDL HEADER END */ /* * Copyright 2001-2003 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. */ - #pragma ident "%Z%%M% %I% %E% SMI" - #include <sys/systeminfo.h> #include <strings.h> #include <rpcsvc/nis.h> #include "nis_parse_ldap_conf.h" --- 18,32 ---- * information: Portions Copyright [yyyy] [name of copyright owner] * * CDDL HEADER END */ /* + * Copyright 2015 Gary Mills * Copyright 2001-2003 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. */ #include <sys/systeminfo.h> #include <strings.h> #include <rpcsvc/nis.h> #include "nis_parse_ldap_conf.h"
*** 213,223 **** free(str); return (0); } for (s = c = 0; s < len; s = e+1) { /* Skip blank space, if any */ ! for (0; str[s] == ' ' || str[s] == '\t'; s++); /* Find delimiter (comma) or end of string */ for (e = s; str[e] != '\0' && str[e] != ','; e++); str[e] = '\0'; tmp = scat(myself, T, sdup(myself, T, "("), scat(myself, F, &str[s], ")")); --- 212,222 ---- free(str); return (0); } for (s = c = 0; s < len; s = e+1) { /* Skip blank space, if any */ ! for (; str[s] == ' ' || str[s] == '\t'; s++); /* Find delimiter (comma) or end of string */ for (e = s; str[e] != '\0' && str[e] != ','; e++); str[e] = '\0'; tmp = scat(myself, T, sdup(myself, T, "("), scat(myself, F, &str[s], ")"));
*** 283,293 **** str = sdup(myself, T, filter); if (str == 0) return (0); for (s = 2; s < len; s = e+1) { /* Skip past the '(' */ ! for (0; s < len && str[s] != '('; s++); s++; if (s >= len) break; for (e = s; str[e] != '\0' && str[e] != ')'; e++); str[e] = '\0'; --- 282,292 ---- str = sdup(myself, T, filter); if (str == 0) return (0); for (s = 2; s < len; s = e+1) { /* Skip past the '(' */ ! for (; s < len && str[s] != '('; s++); s++; if (s >= len) break; for (e = s; str[e] != '\0' && str[e] != ')'; e++); str[e] = '\0';