Erik Faye-Lund <kusmabite@xxxxxxxxx> writes: >>> -static int serve(struct string_list *listen_addr, int listen_port, struct passwd *pass, gid_t gid) >>> +#ifndef NO_POSIX_GOODIES >>> +static struct passwd *pass; >>> +static gid_t gid; >>> +#endif >>> + >>> +static int serve(struct string_list *listen_addr, int listen_port) >>> Â{ >>> Â Â Â struct socketlist socklist = { NULL, 0, 0 }; >>> >> >> This is ugly. ÂWhy did you need to make the arguments file-scope static? >> > > To avoid having different signatures for the serve-function dependent > on NO_POSIX_GOODIES. Why does the signature even have to be different between the two to begin with? I _think_ you have gid_t over there, although you might not have "struct passwd", in which case you can just define an empty one that your alternate implementation is not going to use anyway. This is especially true if you are making the "drop-privileges" part a helper function, no? -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html