[Bug 3097] BB making easily-fixed non-portable assumptions
bugzilla at busybox.net
bugzilla at busybox.net
Sun Jan 16 16:32:13 UTC 2011
https://bugs.busybox.net/show_bug.cgi?id=3097
--- Comment #5 from Denys Vlasenko <vda.linux at googlemail.com> ---
(In reply to comment #4)
> Created attachment 2857 [details]
> config file for which COMMON_BUFSIZE is too small.
I added this test printouts to networking/inetd.c:
int inetd_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE;
int inetd_main(int argc UNUSED_PARAM, char **argv)
{
struct sigaction sa, saved_pipe_handler;
servtab_t *sep, *sep2;
struct passwd *pwd;
struct group *grp = grp; /* for compiler */
int opt;
pid_t pid;
sigset_t omask;
INIT_G();
bb_error_msg("sizeof(G):%ld", (long)sizeof(G));
bb_error_msg("COMMON_BUFSIZE:%ld", (long)COMMON_BUFSIZE);
exit(0);
With your .config, building against 64-bit glibc I see:
$ ./busybox inetd
inetd: sizeof(G):464
inetd: COMMON_BUFSIZE:8193
when I additionally enable all inetd options, I see:
inetd: sizeof(G):608
inetd: COMMON_BUFSIZE:8193
And finally, building this .config against 32-bit uclibc configured for
BUFSIZ=1024, I see:
inetd: sizeof(G):584
inetd: COMMON_BUFSIZE:1025
I don't see the problem. Please explain where is it.
--
Configure bugmail: https://bugs.busybox.net/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
More information about the busybox-cvs
mailing list