Enji Cooper
3e973f9b6d
Fix compiling with gcc [4.2.1] after r287797 when MK_HESOID == no and
...
MK_NIS == no by converting `i` back to an int, and instead cast the loop
comparison to `int`
The loop comparison is iterating the len(ns_dtab)-1, because
the last element is the sentinel tuple { NULL, NULL, NULL, }, so when
both HESOID and NIS are off, len(ns_dtab)-1 == 1 - 1 == 0, and the loop
is skipped because the expression is tautologically false
While here, convert `(sizeof(x) / sizeof(x[0]))` to `nitems(x)`
Tested with: clang 3.7.0, gcc 4.2.1, and gcc 4.9.4 [*] with MK_NIS={no,yes}
and by running bash -lc 'id -u && id -g && id'
* gcc 4.9.4 needs another patch in order for the compile to succeed
with -Werror with lib/libc/gen/getgrent.c
Reported by: jhibbits
2015-10-25 07:42:56 +00:00
..
2015-10-12 08:16:03 +00:00
2015-10-18 17:18:19 +00:00
2015-09-29 16:09:58 +00:00
2015-06-15 19:28:07 +00:00
2015-10-12 18:31:21 +00:00
2015-06-13 19:20:56 +00:00
2015-06-16 23:37:19 +00:00
2015-09-25 19:26:08 +00:00
2015-06-13 19:20:56 +00:00
2015-06-13 19:20:56 +00:00
2015-06-13 19:20:56 +00:00
2015-06-13 19:20:56 +00:00
2015-10-25 07:42:56 +00:00
2015-06-13 19:20:56 +00:00
2015-10-06 21:28:54 +00:00
2015-06-13 19:20:56 +00:00
2015-10-17 09:07:53 +00:00
2015-07-02 21:58:10 +00:00
2015-07-02 21:58:10 +00:00
2015-09-10 20:37:00 +00:00
2015-06-16 23:37:19 +00:00
2015-06-13 19:20:56 +00:00
2015-10-01 19:02:45 +00:00
2015-10-12 08:16:03 +00:00
2015-09-25 19:26:08 +00:00
2015-10-05 17:47:23 +00:00
2015-02-06 16:09:01 +00:00
2015-06-13 19:20:56 +00:00
2015-06-13 19:20:56 +00:00
2015-10-23 07:36:27 +00:00
2015-06-16 23:37:19 +00:00
2015-06-15 19:28:07 +00:00
2015-06-13 19:20:56 +00:00
2015-06-15 20:11:15 +00:00
2015-09-25 19:26:08 +00:00
2015-06-13 19:20:56 +00:00
2015-06-15 19:28:07 +00:00
2015-10-16 12:53:22 +00:00
2015-10-23 07:37:27 +00:00
2015-08-28 06:41:40 +00:00
2015-07-01 16:50:01 +00:00
2015-06-13 19:20:56 +00:00
2015-10-15 22:55:08 +00:00
2015-07-03 20:09:14 +00:00
2015-06-15 19:28:07 +00:00
2015-06-15 19:28:07 +00:00
2015-08-20 11:07:51 +00:00
2015-06-16 23:37:19 +00:00
2015-09-18 23:49:32 +00:00
2015-09-23 05:39:20 +00:00
2015-07-12 03:39:36 +00:00
2015-06-13 19:20:56 +00:00
2015-09-25 19:26:08 +00:00
2015-10-12 08:16:03 +00:00
2015-06-15 19:28:07 +00:00
2015-06-13 19:20:56 +00:00
2015-06-13 19:20:56 +00:00
2015-06-13 19:20:56 +00:00
2015-10-12 08:16:03 +00:00
2015-10-03 20:06:50 +00:00
2015-06-16 23:37:19 +00:00
2015-10-12 08:16:03 +00:00
2015-06-15 19:28:07 +00:00
2015-06-15 19:28:07 +00:00
2015-10-14 16:56:25 +00:00
2015-10-12 08:16:03 +00:00
2015-10-06 18:07:00 +00:00
2015-06-16 23:37:19 +00:00
2015-09-25 19:26:08 +00:00
2015-06-13 19:20:56 +00:00
2015-10-12 08:16:03 +00:00
2015-06-13 19:20:56 +00:00
2015-06-16 23:37:19 +00:00
2015-06-13 19:20:56 +00:00
2015-09-17 05:06:34 +00:00
2015-09-25 19:26:08 +00:00
2015-06-13 19:20:56 +00:00
2015-06-13 19:20:56 +00:00
2015-08-09 05:54:53 +00:00
2015-10-08 17:59:05 +00:00
2015-09-25 19:26:08 +00:00
2015-09-25 19:26:08 +00:00
2015-06-13 19:20:56 +00:00
2015-06-13 19:20:56 +00:00
2015-10-12 08:16:03 +00:00
2015-06-16 23:37:19 +00:00
2015-06-13 19:20:56 +00:00
2015-06-15 19:28:07 +00:00
2015-09-29 18:48:12 +00:00
2015-06-15 19:28:07 +00:00
2015-09-25 19:26:08 +00:00
2015-10-03 16:34:21 +00:00
2015-06-13 19:20:56 +00:00
2015-10-12 08:16:03 +00:00
2015-09-25 19:26:08 +00:00
2015-07-06 19:41:43 +00:00
2015-06-13 19:20:56 +00:00
2015-10-18 07:30:50 +00:00
2015-06-13 19:20:56 +00:00
2015-06-16 23:37:19 +00:00
2015-10-03 16:34:21 +00:00
2015-10-12 08:16:03 +00:00
2015-09-26 01:04:52 +00:00
2015-10-12 08:16:03 +00:00
2015-10-15 20:49:20 +00:00