]> granicus.if.org Git - shadow/log
shadow
16 years ago * libmisc/age.c: fork() and wait return a pid_t, not an int.
nekral-guest [Fri, 13 Jun 2008 19:24:27 +0000 (19:24 +0000)]
* libmisc/age.c: fork() and wait return a pid_t, not an int.
* libmisc/age.c: Avoid implicit conversion of pointers to
booleans.
* libmisc/age.c: Avoid assignments in comparisons.
* libmisc/age.c: Ignore the return value of printf(), puts(),
fputs() and fflush().
* libmisc/age.c: Add brackets and parenthesis.
* libmisc/age.c: Cast the return value of time() to long and
converted to a date.

16 years ago * libmisc/rlogin.c: The size argument of read() is a size_t.
nekral-guest [Fri, 13 Jun 2008 18:34:27 +0000 (18:34 +0000)]
* libmisc/rlogin.c: The size argument of read() is a size_t.
Propagate this time to the callers (the get_remote_string() and
do_rlogin() functions).
* libmisc/rlogin.c: Add brackets and parenthesis.
* libmisc/rlogin.c: Avoid multi-statements lines.
* libmisc/rlogin.c: Avoid assignments in comparisons.
* libmisc/rlogin.c: Avoid implicit conversion of pointers to
booleans.

16 years ago * libmisc/failure.c: Avoid assignments in comparisons.
nekral-guest [Fri, 13 Jun 2008 18:31:13 +0000 (18:31 +0000)]
* libmisc/failure.c: Avoid assignments in comparisons.
* libmisc/failure.c: read() returns a ssize_t.
* libmisc/failure.c: Add brackets and parenthesis.
* libmisc/failure.c: Ignore return value of time() when use with a
non NULL argument.

16 years ago * libmisc/chowntty.c: Avoid assignments in comparisons.
nekral-guest [Fri, 13 Jun 2008 18:29:02 +0000 (18:29 +0000)]
* libmisc/chowntty.c: Avoid assignments in comparisons.
* libmisc/chowntty.c: Avoid implicit conversion of pointers to
booleans.
* libmisc/chowntty.c: Add brackets and parenthesis.

16 years ago * libmisc/audit_help.c: Add brackets.
nekral-guest [Fri, 13 Jun 2008 18:24:37 +0000 (18:24 +0000)]
* libmisc/audit_help.c: Add brackets.

16 years ago * libmisc/addgrps.c: Avoid implicit conversion of pointers to
nekral-guest [Fri, 13 Jun 2008 18:19:34 +0000 (18:19 +0000)]
* libmisc/addgrps.c: Avoid implicit conversion of pointers to
booleans.
* libmisc/addgrps.c: Add brackets.

16 years ago * libmisc/utmp.c: Avoid implicit conversion of pointers to
nekral-guest [Fri, 13 Jun 2008 18:17:10 +0000 (18:17 +0000)]
* libmisc/utmp.c: Avoid implicit conversion of pointers to
booleans
+ add missing changelog from last commit.

16 years ago * libmisc/console.c, libmisc/hushed.c, libmisc/yesno.c,
nekral-guest [Fri, 13 Jun 2008 18:11:09 +0000 (18:11 +0000)]
* libmisc/console.c, libmisc/hushed.c, libmisc/yesno.c,
libmisc/loginprompt.c, libmisc/ttytype.c, libmisc/tz.c,
src/login_nopam.c, src/chpasswd.c, src/chgpasswd.c, lib/port.c:
The size argument of fgets is an int, not a size_t.
* libmisc/loginprompt.c: Ignore the return value from signal()
when the signal handlers are restored.
* src/chpasswd.c: Cast the return value of time() to a long
integer.
* src/chpasswd.c: Use the SCALE macro instead of (24L * 3600L)
for the values to be set in /etc/shadow.

16 years agoAvoid implicit conversion of pointers to booleans.
nekral-guest [Tue, 10 Jun 2008 22:10:47 +0000 (22:10 +0000)]
Avoid implicit conversion of pointers to booleans.

16 years agoAdd brackets.
nekral-guest [Tue, 10 Jun 2008 22:10:21 +0000 (22:10 +0000)]
Add brackets.

16 years ago * src/pwck.c: Use a bool when possible instead of int integers.
nekral-guest [Tue, 10 Jun 2008 22:09:12 +0000 (22:09 +0000)]
* src/pwck.c: Use a bool when possible instead of int integers.
* src/pwck.c: Avoid implicit conversion of integers to booleans.

16 years ago * src/su.c: Use a bool when possible instead of int integers.
nekral-guest [Tue, 10 Jun 2008 22:07:51 +0000 (22:07 +0000)]
* src/su.c: Use a bool when possible instead of int integers.
* src/su.c: Add brackets and parenthesis.
* src/su.c: Avoid implicit conversion of pointers / integers
/ chars to booleans.
* src/su.c: Ignore the return value of pam_end() before
exiting.
* src/su.c: Avoid assignments in comparisons.
* src/su.c: Avoid multi-statements lines.

16 years ago * lib/prototypes.h, libmisc/valid.c: Change the prototype of
nekral-guest [Tue, 10 Jun 2008 21:52:34 +0000 (21:52 +0000)]
* lib/prototypes.h, libmisc/valid.c: Change the prototype of
valid() to return a bool.
* libmisc/valid.c: Add parenthesis.

16 years agoAvoid implicit conversion of integer to boolean.
nekral-guest [Tue, 10 Jun 2008 20:34:25 +0000 (20:34 +0000)]
Avoid implicit conversion of integer to boolean.

16 years ago * lib/commonio.c: Add brackets and parenthesis.
nekral-guest [Tue, 10 Jun 2008 20:27:16 +0000 (20:27 +0000)]
* lib/commonio.c: Add brackets and parenthesis.
* lib/commonio.c: Check the result of fgets().
* lib/commonio.c: Avoid implicit conversion of pointers to
booleans.

16 years ago * lib/prototypes.h: Fix the prototypes to match earlier changes.
nekral-guest [Tue, 10 Jun 2008 20:02:47 +0000 (20:02 +0000)]
* lib/prototypes.h: Fix the prototypes to match earlier changes.

16 years agoFix typo. Compil fix.
nekral-guest [Tue, 10 Jun 2008 20:02:12 +0000 (20:02 +0000)]
Fix typo. Compil fix.

16 years ago * lib/nscd.c: Include defines.h.
nekral-guest [Tue, 10 Jun 2008 20:01:55 +0000 (20:01 +0000)]
* lib/nscd.c: Include defines.h.
* lib/nscd.c: Always warn when the nscd cache cannot be flushed.
* lib/nscd.c: Avoid assignments in comparisons.
* lib/nscd.c: Ignore the return value of fputs() when printing
errors.

16 years ago * lib/port.c: Add brackets and parenthesis.
nekral-guest [Tue, 10 Jun 2008 19:59:26 +0000 (19:59 +0000)]
* lib/port.c: Add brackets and parenthesis.
* lib/port.c: Change isttytime() prototype to return a bool.
* lib/port.c: Ignore the return value of fclose () (file open
read-only).
* lib/port.c: Avoid multi-statements lines.

16 years ago * src/id.c: Ignore the return value of fputs(), puts(), putchar(),
nekral-guest [Tue, 10 Jun 2008 19:45:06 +0000 (19:45 +0000)]
* src/id.c: Ignore the return value of fputs(), puts(), putchar(),
and printf().
* src/id.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().
* src/id.c: Add brackets and parenthesis.
* src/id.c: Avoid implicit conversion of pointers / integers
to booleans.

16 years ago * src/chsh.c: Use a bool when possible instead of int integers.
nekral-guest [Tue, 10 Jun 2008 19:42:22 +0000 (19:42 +0000)]
* src/chsh.c: Use a bool when possible instead of int integers.
* src/chsh.c: restricted_shell() renamed is_restricted_shell().
check_shell() renamed shell_is_listed().
* src/chsh.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().
* src/chsh.c: Avoid implicit conversion of pointers / integers
to booleans.
* src/chsh.c: Ignore the return value of pam_end() before
exiting.

16 years ago * src/grpunconv.c: Use a bool when possible instead of int
nekral-guest [Tue, 10 Jun 2008 19:39:18 +0000 (19:39 +0000)]
* src/grpunconv.c: Use a bool when possible instead of int
integers.
* src/grpunconv.c: Add brackets and parenthesis.
* src/grpunconv.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().
* src/grpunconv.c: Avoid implicit conversion of pointers / integers
to booleans.

16 years ago * src/sulogin.c: Ignore return value of setlocale(),
nekral-guest [Tue, 10 Jun 2008 19:36:05 +0000 (19:36 +0000)]
* src/sulogin.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().
* src/sulogin.c: Avoid implicit conversion of pointers / integers
/ chars to booleans.
* src/sulogin.c: Avoid assignments in comparisons.
* src/sulogin.c: Ignore the return value of alarm().

16 years ago * src/groups.c: Use a bool when possible instead of int integers.
nekral-guest [Tue, 10 Jun 2008 19:29:54 +0000 (19:29 +0000)]
* src/groups.c: Use a bool when possible instead of int integers.
* src/groups.c: Add brackets and parenthesis.
* src/groups.c: Avoid implicit conversion of pointers / integers
to booleans.
* src/groups.c: Avoid assignments in comparisons.
* src/groups.c: Ignore the return value of putchar(), printf()
* src/groups.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().

16 years agore-indent.
nekral-guest [Tue, 10 Jun 2008 19:18:44 +0000 (19:18 +0000)]
re-indent.

16 years ago * src/grpconv.c: Use a bool when possible instead of int integers.
nekral-guest [Tue, 10 Jun 2008 19:18:34 +0000 (19:18 +0000)]
* src/grpconv.c: Use a bool when possible instead of int integers.
* src/grpconv.c: Add brackets and parenthesis.
* src/grpconv.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().
* src/grpconv.c: Avoid implicit conversion of pointers / integers
to booleans.

16 years ago * src/faillog.c: Use a bool when possible instead of int integers.
nekral-guest [Tue, 10 Jun 2008 19:16:02 +0000 (19:16 +0000)]
* src/faillog.c: Use a bool when possible instead of int integers.
* src/faillog.c: Avoid implicit conversion of pointers / integers
/ chars to booleans.
* src/faillog.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().
* src/faillog.c: Add brackets and parenthesis.

16 years ago * src/login.c: Avoid multi-statements lines.
nekral-guest [Tue, 10 Jun 2008 18:56:23 +0000 (18:56 +0000)]
* src/login.c: Avoid multi-statements lines.
* src/login.c: Ignore the return value of pam_end() before
exiting.
* src/login.c: Use a bool when possible instead of int integers.
* src/login.c: Add brackets and parenthesis.
* src/login.c: Ignore the return values of fflush(), putchar(), puts().
* src/login.c: Ignore the return value of fclose() for read-only
files.
* src/login.c: Avoid assignments in comparisons.
* src/login.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().

16 years ago * src/chage.c: Use a bool when possible instead of int integers.
nekral-guest [Tue, 10 Jun 2008 17:56:53 +0000 (17:56 +0000)]
* src/chage.c: Use a bool when possible instead of int integers.
* src/chage.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().

16 years ago * src/groupadd.c: Use a bool when possible instead of int
nekral-guest [Tue, 10 Jun 2008 17:53:35 +0000 (17:53 +0000)]
* src/groupadd.c: Use a bool when possible instead of int
integers.
* src/groupadd.c: Add brackets and parenthesis.
* src/groupadd.c: Avoid implicit conversion of pointers / integers
/ chars to booleans.
* src/groupadd.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().
* src/groupadd.c: Ignore the return value of pam_end() before
exiting.

16 years ago * src/pwck.c: Use a bool when possible instead of int integers.
nekral-guest [Tue, 10 Jun 2008 17:51:30 +0000 (17:51 +0000)]
* src/pwck.c: Use a bool when possible instead of int integers.
* src/pwck.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().

16 years ago * src/passwd.c: Use a bool when possible instead of int integers.
nekral-guest [Tue, 10 Jun 2008 17:50:21 +0000 (17:50 +0000)]
* src/passwd.c: Use a bool when possible instead of int integers.
* src/passwd.c: Avoid assignments in comparisons.
* src/passwd.c: Add brackets and parenthesis.
* src/passwd.c: Avoid implicit conversion of pointers / integers /
chars to booleans.
* src/passwd.c: Move the "context_t c" declaration at the
beginning check_selinux_access.
* src/passwd.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().

16 years ago * src/groupmod.c: Use a bool when possible instead of int
nekral-guest [Tue, 10 Jun 2008 17:45:08 +0000 (17:45 +0000)]
* src/groupmod.c: Use a bool when possible instead of int
integers.
* src/groupmod.c: Avoid assignments in comparisons.
* src/groupmod.c: Add brackets and parenthesis.
* src/groupmod.c: Avoid implicit conversion of pointers / integers
/ chars to booleans.
* src/groupmod.c: Use a %lu format to print GIDs, and cast the GID
to (unsigned long int).
* src/groupmod.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().
* src/groupmod.c: Ignore the return value of pam_end() before
exiting.

16 years ago * src/su.c: Ignore return value of setlocale(),
nekral-guest [Mon, 9 Jun 2008 22:28:16 +0000 (22:28 +0000)]
* src/su.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().

16 years ago * src/useradd.c: Use a bool when possible instead of int integers.
nekral-guest [Mon, 9 Jun 2008 22:08:08 +0000 (22:08 +0000)]
* src/useradd.c: Use a bool when possible instead of int integers.
* src/useradd.c: Avoid implicit conversion of pointers / integers
/ chars to booleans.
* src/useradd.c: Add brackets and parenthesis.
* src/useradd.c: Avoid assignments in comparisons.
* src/useradd.c: Ignore the return value of fclose() for read-only
files.
* src/useradd.c: Ignore the return value of fflush() before
closing the files.
* src/useradd.c: Avoid multi-statements lines.
* src/useradd.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().
* src/useradd.c: Ignore the return value of pam_end() before
exiting.

16 years ago * src/vipw.c: Use a bool when possible instead of int integers.
nekral-guest [Mon, 9 Jun 2008 21:18:28 +0000 (21:18 +0000)]
* src/vipw.c: Use a bool when possible instead of int integers.
* src/vipw.c: Ignore the return value of umask(), when the mask is
set again to the old value.
* src/vipw.c: Avoid implicit conversion of pointers / integers to
booleans.
* src/vipw.c: Add brackets and parenthesis.
* src/vipw.c: Avoid assignments in comparisons.
* src/vipw.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().
* src/vipw.c: Add missing termination of the longopts parameter
for getopt_long().

16 years ago * src/chgpasswd.c: Use a bool when possible instead of int
nekral-guest [Mon, 9 Jun 2008 20:56:03 +0000 (20:56 +0000)]
* src/chgpasswd.c: Use a bool when possible instead of int
integers.
* src/chgpasswd.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().
* src/chgpasswd.c: Avoid implicit conversion of integers to
booleans.

16 years ago * src/groupdel.c: Use a bool when possible instead of int
nekral-guest [Mon, 9 Jun 2008 20:54:04 +0000 (20:54 +0000)]
* src/groupdel.c: Use a bool when possible instead of int
integers.
* src/groupdel.c: Avoid implicit conversion of pointers / integers to
booleans.
* src/groupdel.c: Avoid assignments in comparisons.
* src/groupdel.c: Ignore the return value of pam_end() before
exiting.
* src/groupdel.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().

16 years ago * src/expiry.c: Ignore return value of setlocale(),
nekral-guest [Mon, 9 Jun 2008 20:36:24 +0000 (20:36 +0000)]
* src/expiry.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().
* src/expiry.c: Add brackets and parenthesis.
* src/expiry.c: Avoid assignments in comparisons.
* src/expiry.c: Avoid implicit conversion of pointers to booleans.

16 years agoAdd brackets and parenthesis.
nekral-guest [Mon, 9 Jun 2008 20:32:17 +0000 (20:32 +0000)]
Add brackets and parenthesis.

16 years ago * src/pwunconv.c: Use a bool when possible instead of int
nekral-guest [Mon, 9 Jun 2008 20:30:34 +0000 (20:30 +0000)]
* src/pwunconv.c: Use a bool when possible instead of int
integers.
* src/pwunconv.c: Add brackets and parenthesis.
* src/pwunconv.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().
* src/pwunconv.c: Avoid implicit conversion of pointers / integers
/ chars to booleans.
* src/pwunconv.c: Avoid assignments in comparisons.

16 years ago * src/usermod.c: Use a bool when possible instead of int integers.
nekral-guest [Mon, 9 Jun 2008 20:17:48 +0000 (20:17 +0000)]
* src/usermod.c: Use a bool when possible instead of int integers.
* src/usermod.c: Add brackets and parenthesis.
* src/usermod.c: Avoid implicit conversion of pointers / integers
/ chars to booleans.
* src/usermod.c: Avoid assignments in comparisons.
* src/usermod.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().
* src/usermod.c: Ignore the return value of pam_end() before
exiting.

16 years ago * src/groupmems.c: Move the declaration of option_index and
nekral-guest [Mon, 9 Jun 2008 20:09:38 +0000 (20:09 +0000)]
* src/groupmems.c: Move the declaration of option_index and
long_options before the blocks of code.
* src/groupmems.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().
* src/groupmems.c: Ignore the return value of pam_end() before
exiting.

16 years ago * src/chfn.c: Use a bool when possible instead of int integers.
nekral-guest [Mon, 9 Jun 2008 20:05:13 +0000 (20:05 +0000)]
* src/chfn.c: Use a bool when possible instead of int integers.
* src/chfn.c: Avoid implicit conversion of integers / chars to
booleans.
* src/chfn.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().

16 years ago * src/logoutd.c: Use a bool when possible instead of int integers.
nekral-guest [Mon, 9 Jun 2008 20:02:46 +0000 (20:02 +0000)]
* src/logoutd.c: Use a bool when possible instead of int integers.
* src/logoutd.c: Avoid implicit conversion of pointers / integers
/ chars to booleans.
* src/logoutd.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().
* src/logoutd.c: Add brackets and parenthesis.

16 years ago * src/chpasswd.c: Use a bool when possible instead of int
nekral-guest [Mon, 9 Jun 2008 19:46:11 +0000 (19:46 +0000)]
* src/chpasswd.c: Use a bool when possible instead of int
integers.
* src/chpasswd.c: Avoid implicit conversion of pointers / integers
/ chars to booleans.
* src/chpasswd.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().

16 years ago * src/pwconv.c: Use a bool when possible instead of int integers.
nekral-guest [Mon, 9 Jun 2008 19:43:22 +0000 (19:43 +0000)]
* src/pwconv.c: Use a bool when possible instead of int integers.
* src/pwconv.c: Add brackets and parenthesis.
* src/pwconv.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().
* src/pwconv.c: Avoid implicit conversion of pointers / integers /
chars to booleans.

16 years ago * NEWS, src/newusers.c: Implement the -r, --system option.
nekral-guest [Mon, 9 Jun 2008 19:36:08 +0000 (19:36 +0000)]
* NEWS, src/newusers.c: Implement the -r, --system option.
* src/newusers.c: Use a bool when possible instead of int
integers.
* src/newusers.c: Avoid implicit conversion of pointers / integers
/ chars to booleans.
* src/newusers.c: Ignore the return value of pam_end() before
exiting.
* src/newusers.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().
* src/newusers.c: Avoid multi-statements lines.
* src/newusers.c: Add brackets and parenthesis.

16 years ago * src/gpasswd.c: Use a bool when possible instead of int integers.
nekral-guest [Mon, 9 Jun 2008 19:26:19 +0000 (19:26 +0000)]
* src/gpasswd.c: Use a bool when possible instead of int integers.
* src/gpasswd.c: Avoid implicit conversion of pointers / integers
/ chars to booleans.
* src/gpasswd.c: Ignore the return value of putchar() and fflush()
before exiting.
* src/gpasswd.c: check_list() renamed is_valid_user_list(), and
return a bool.
* src/gpasswd.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().

16 years ago * src/grpck.c: Use a bool when possible instead of int integers.
nekral-guest [Mon, 9 Jun 2008 19:20:00 +0000 (19:20 +0000)]
* src/grpck.c: Use a bool when possible instead of int integers.
* src/grpck.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().

16 years ago * src/lastlog.c: Use a bool when possible instead of int integers.
nekral-guest [Mon, 9 Jun 2008 19:15:27 +0000 (19:15 +0000)]
* src/lastlog.c: Use a bool when possible instead of int integers.
* src/lastlog.c: Avoid implicit conversion of pointers / integers
/ chars to booleans.
* src/lastlog.c: Add brackets and parenthesis.
* src/lastlog.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().

16 years ago * src/userdel.c: Use a bool for the is_shadow_pwd, is_shadow_grp,
nekral-guest [Mon, 9 Jun 2008 19:10:44 +0000 (19:10 +0000)]
* src/userdel.c: Use a bool for the is_shadow_pwd, is_shadow_grp,
deleted_user_group, was_member, was_admin, and the
options' flags.
* src/userdel.c: Change path_prefix() prototype to return a bool.
* src/userdel.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().
* src/userdel.c: Ignore the return value from pam_end() since we
are exiting anyway just afterwards.
* src/userdel.c: Avoid implicit conversion of pointers /
integers / chars to booleans.
* src/userdel.c: Add brackets and parenthesis.
* src/userdel.c: Avoid assignments in comparisons.
* src/userdel.c: Do not ignore the return value of the *_unlock()
functions.

16 years ago * src/login_nopam.c: Do not use the YES and NO macros. Use the
nekral-guest [Mon, 9 Jun 2008 18:35:32 +0000 (18:35 +0000)]
* src/login_nopam.c: Do not use the YES and NO macros. Use the
booleans true and false instead. Change the prototypes of
list_match(), user_match(), from_match(), and string_match()
accordingly. Also use booleans internally.
* src/login_nopam.c: Add brackets and parenthesis.
* src/login_nopam.c: Avoid implicit conversion of pointers /
integers / chars to booleans.
* src/login_nopam.c: Avoid assignments in comparisons.

16 years ago * src/newgrp.c: Use a bool for is_newgrp, notfound, needspasswd,
nekral-guest [Mon, 9 Jun 2008 18:23:23 +0000 (18:23 +0000)]
* src/newgrp.c: Use a bool for is_newgrp, notfound, needspasswd,
initflag, and cflag.
* src/newgrp.c: Add brackets and parenthesis.
* src/newgrp.c: Avoid implicit conversion of pointers / integers /
chars to booleans.
* src/newgrp.c: Avoid multi-statements lines.
* src/newgrp.c: Ignore return value of setlocale(),
bindtextdomain(), and textdomain().
* src/newgrp.c: Avoid assignments in comparisons.

16 years ago * libmisc/list.c: Change is_on_list() prototype to return a bool.
nekral-guest [Mon, 9 Jun 2008 18:13:52 +0000 (18:13 +0000)]
* libmisc/list.c: Change is_on_list() prototype to return a bool.

16 years ago * libmisc/find_new_ids.c: Change find_new_uid() and find_new_gid()
nekral-guest [Mon, 9 Jun 2008 18:13:09 +0000 (18:13 +0000)]
* libmisc/find_new_ids.c: Change find_new_uid() and find_new_gid()
prototypes to use a bool for their first argument (sys_user /
sys_group).

16 years ago * libmisc/console.c: Change is_listed() prototype to return a bool.
nekral-guest [Mon, 9 Jun 2008 18:11:20 +0000 (18:11 +0000)]
* libmisc/console.c: Change is_listed() prototype to return a bool.
The default parameter should also be a bool.
* libmisc/console.c: Add brackets and parenthesis.
* libmisc/console.c: Avoid assignments in comparisons.
* libmisc/console.c: Change console() prototype to return a bool.

16 years ago * lib/sgetspent.c: Add brackets and parenthesis.
nekral-guest [Mon, 26 May 2008 09:39:29 +0000 (09:39 +0000)]
* lib/sgetspent.c: Add brackets and parenthesis.
* lib/sgetspent.c: Avoid assignments in comparisons.
* lib/sgetspent.c: Avoid implicit conversion of pointers / chars to booleans.
* lib/sgetspent.c: Avoid multi-statements lines.

16 years agoAvoid assignments in comparisons.
nekral-guest [Mon, 26 May 2008 09:22:44 +0000 (09:22 +0000)]
Avoid assignments in comparisons.
Add note about possible bug.

16 years agoDo not check twice if fields[2] and fields[3] are not empty.
nekral-guest [Mon, 26 May 2008 09:17:17 +0000 (09:17 +0000)]
Do not check twice if fields[2] and fields[3] are not empty.

16 years ago * lib/sgetpwent.c: Avoid implicit conversion of pointers / chars to booleans.
nekral-guest [Mon, 26 May 2008 09:15:02 +0000 (09:15 +0000)]
* lib/sgetpwent.c: Avoid implicit conversion of pointers / chars to booleans.
* lib/sgetpwent.c: Add brackets and parenthesis.
* lib/sgetpwent.c: Return NULL instead of 0.

16 years ago* Avoid implicit conversion of pointers to booleans.
nekral-guest [Mon, 26 May 2008 09:12:34 +0000 (09:12 +0000)]
* Avoid implicit conversion of pointers to booleans.
* Add parenthesis.

16 years ago * libmisc/getdate.y: abbrev is a bool.
nekral-guest [Mon, 26 May 2008 08:59:54 +0000 (08:59 +0000)]
* libmisc/getdate.y: abbrev is a bool.
* libmisc/getdate.y: Avoid implicit conversion of pointers / chars / integers to booleans.

16 years ago * lib/prototypes.h: Fix prototypes according to earlier changes (usage of the bool...
nekral-guest [Mon, 26 May 2008 08:56:34 +0000 (08:56 +0000)]
* lib/prototypes.h: Fix prototypes according to earlier changes (usage of the bool type).
* lib/prototypes.h: Add the arguments' name to the prototypes.

16 years agoAdd protection against multiple inclusions.
nekral-guest [Mon, 26 May 2008 08:53:56 +0000 (08:53 +0000)]
Add protection against multiple inclusions.

16 years agoIndicate that defines.h is included for the definition of the "bool" type.
nekral-guest [Mon, 26 May 2008 08:52:34 +0000 (08:52 +0000)]
Indicate that defines.h is included for the definition of the "bool" type.

16 years agoThe changed, isopen, locked, and readonly fields of the db are booleans.
nekral-guest [Mon, 26 May 2008 08:51:45 +0000 (08:51 +0000)]
The changed, isopen, locked, and readonly fields of the db are booleans.

16 years ago * lib/pwio.h: Add protection against multiple inclusions.
nekral-guest [Mon, 26 May 2008 08:49:44 +0000 (08:49 +0000)]
* lib/pwio.h: Add protection against multiple inclusions.
* lib/pwio.c: The changed, isopen, locked, and readonly fields of the db are booleans.

16 years ago * lib/sgroupio.c: Avoid assignments in comparisons.
nekral-guest [Mon, 26 May 2008 08:46:41 +0000 (08:46 +0000)]
* lib/sgroupio.c: Avoid assignments in comparisons.
* lib/sgroupio.c: Add brackets.
* lib/sgroupio.c: Avoid implicit conversion of pointers / integers to booleans.
* lib/sgroupio.c: The changed, isopen, locked, and readonly fields of the db are booleans.
* lib/sgroupio.h, lib/sgroupio.c: sgr_file_present returns a bool.
* lib/sgroupio.h: Add protection against multiple inclusions.

16 years ago * lib/shadowio.h, lib/shadowio.c: spw_file_present returns a bool.
nekral-guest [Mon, 26 May 2008 08:45:34 +0000 (08:45 +0000)]
* lib/shadowio.h, lib/shadowio.c: spw_file_present returns a bool.
* lib/shadowio.h: Add protection against multiple inclusions.

16 years ago * lib/sgroupio.c: Avoid assignments in comparisons.
nekral-guest [Mon, 26 May 2008 08:43:50 +0000 (08:43 +0000)]
* lib/sgroupio.c: Avoid assignments in comparisons.
* lib/sgroupio.c: Add brackets.
* lib/sgroupio.c: Avoid implicit conversion of pointers / integers to booleans.
* lib/sgroupio.c: The changed, isopen, locked, and readonly fields of the db are booleans.
* lib/sgroupio.h, lib/sgroupio.c: sgr_file_present returns a bool.
* lib/sgroupio.h: Add protection against multiple inclusions.

16 years ago * lib/gshadow.c: nis_used and nis_bound are booleans.
nekral-guest [Mon, 26 May 2008 08:40:04 +0000 (08:40 +0000)]
* lib/gshadow.c: nis_used and nis_bound are booleans.
* lib/gshadow.c: Avoid implicit conversion of pointers / integers to booleans.
* lib/gshadow.c: Avoid assignments in comparisons.
* lib/gshadow.c: Add brackets.

16 years agoAdd protection against multiple inclusion
nekral-guest [Mon, 26 May 2008 08:35:13 +0000 (08:35 +0000)]
Add protection against multiple inclusion

16 years agoThe changed, isopen, locked, and readonly fields of the db are booleans.
nekral-guest [Mon, 26 May 2008 08:34:04 +0000 (08:34 +0000)]
The changed, isopen, locked, and readonly fields of the db are booleans.

16 years ago * lib/sgetgrent.c: implicit conversion of pointers / chars to booleans.
nekral-guest [Mon, 26 May 2008 08:31:14 +0000 (08:31 +0000)]
* lib/sgetgrent.c: implicit conversion of pointers / chars to booleans.
* lib/sgetgrent.c: Avoid assignments in comparisons.
* lib/sgetgrent.c: Add brackets.

16 years ago * lib/encrypt.c: Avoid implicit conversion of pointers to booleans.
nekral-guest [Mon, 26 May 2008 01:07:13 +0000 (01:07 +0000)]
* lib/encrypt.c: Avoid implicit conversion of pointers to booleans.
* lib/encrypt.c: Add parenthesis.

16 years ago * lib/port.c: Avoid implicit conversion of pointers / integers / chars to booleans.
nekral-guest [Mon, 26 May 2008 01:05:04 +0000 (01:05 +0000)]
* lib/port.c: Avoid implicit conversion of pointers / integers / chars to booleans.
* lib/port.c: Avoid multiple statement on the same line.
* lib/port.c: Add brackets and parenthesis.
* lib/port.c: Avoid assignments in comparisons.
* lib/port.c: Fix typo comparision -> comparison (in comment).

16 years ago * lib/fputsx.c: Add brackets.
nekral-guest [Mon, 26 May 2008 00:59:42 +0000 (00:59 +0000)]
* lib/fputsx.c: Add brackets.
* lib/fputsx.c: Avoid assignments in comparisons.
* lib/fputsx.c: Avoid implicit conversion of pointers / integers / chars to booleans.

16 years ago * lib/commonio.h: commonio_entry.changed, commonio_db.changed, commonio_db.isopen...
nekral-guest [Mon, 26 May 2008 00:46:25 +0000 (00:46 +0000)]
* lib/commonio.h: commonio_entry.changed, commonio_db.changed, commonio_db.isopen, commonio_db.locked, and commonio_db.readonly are no booleans.
* lib/commonio.h: Include defines.h to get the definition of bool.
* lib/commonio.h: commonio_present returns a bool
* lib/commonio.c: Implement above changes.
* lib/commonio.c: add argument names in prototypes.
* lib/commonio.c: name_is_nis returns a bool.
* lib/commonio.c: nscd_need_reload is a bool.
* lib/commonio.c: Improve types (use size_t / pid_t when needed instead of int).
* lib/commonio.c: Avoid assignments in comparisons.
* lib/commonio.c: Add brackets and parenthesis.
* lib/commonio.c: Avoid implicit conversion of pointers / integers to booleans
* lib/commonio.c: The return values of utime is not checked on purpose.

16 years agocheckutmp is implemented twice. I only changed the second one. Now fix the
nekral-guest [Mon, 26 May 2008 00:26:33 +0000 (00:26 +0000)]
checkutmp is implemented twice. I only changed the second one. Now fix the
first one.

16 years ago * libmisc/isexpired.c: ARGSUSED is no more needed (shadow is always supported).
nekral-guest [Mon, 26 May 2008 00:14:10 +0000 (00:14 +0000)]
* libmisc/isexpired.c: ARGSUSED is no more needed (shadow is always supported).
* libmisc/isexpired.c: Avoid implicit conversion of pointers to booleans.
* libmisc/isexpired.c: Add brackets and parenthesis.

16 years ago * libmisc/sulog.c (sulog): The success argument is a bool.
nekral-guest [Mon, 26 May 2008 00:09:24 +0000 (00:09 +0000)]
* libmisc/sulog.c (sulog): The success argument is a bool.
* libmisc/sulog.c: The return values of fflush is not checked on purpose.
* libmisc/sulog.c: Indicate that some return values should be checked.

16 years agoUpdated copyright dates.
nekral-guest [Mon, 26 May 2008 00:04:30 +0000 (00:04 +0000)]
Updated copyright dates.

16 years ago * libmisc/ttytype.c: Avoid implicit conversion of pointers / integers to booleans.
nekral-guest [Mon, 26 May 2008 00:02:15 +0000 (00:02 +0000)]
* libmisc/ttytype.c: Avoid implicit conversion of pointers / integers to booleans.
* libmisc/ttytype.c: Avoid assignments in comparisons.
* libmisc/ttytype.c: Add brackets and parenthesis.
* libmisc/ttytype.c: The return values of fclose is not checked on purpose.

16 years ago * libmisc/mail.c: Avoid implicit conversion of pointers to booleans.
nekral-guest [Sun, 25 May 2008 23:59:05 +0000 (23:59 +0000)]
* libmisc/mail.c: Avoid implicit conversion of pointers to booleans.
* libmisc/mail.c: Avoid assignments in comparisons.

16 years ago * libmisc/loginprompt.c: Avoid implicit conversion of pointers / chars to booleans.
nekral-guest [Sun, 25 May 2008 23:57:41 +0000 (23:57 +0000)]
* libmisc/loginprompt.c: Avoid implicit conversion of pointers / chars to booleans.
* libmisc/loginprompt.c: Add brackets.
* libmisc/loginprompt.c: Avoid assignments in comparisons.
* libmisc/loginprompt.c: The return values of fclose and fflush are not checked on purpose.

16 years agoAvoid implicit conversion of chars to booleans.
nekral-guest [Sun, 25 May 2008 23:50:03 +0000 (23:50 +0000)]
Avoid implicit conversion of chars to booleans.

16 years agoselinux_checked, selinux_enabled, and set_orig are now booleans.
nekral-guest [Sun, 25 May 2008 23:45:21 +0000 (23:45 +0000)]
selinux_checked, selinux_enabled, and set_orig are now booleans.

16 years ago * libmisc/setugid.c (setup_uid_gid): The is_console argument is now a bool.
nekral-guest [Sun, 25 May 2008 23:42:39 +0000 (23:42 +0000)]
* libmisc/setugid.c (setup_uid_gid): The is_console argument is now a bool.
* libmisc/setugid.c: Avoid implicit conversion of integers / pointers to booleans.
* libmisc/setugid.c: Add brackets.

16 years ago * libmisc/setugid.c (setup_uid_gid): The is_console argument is no a bool.
nekral-guest [Sun, 25 May 2008 23:39:59 +0000 (23:39 +0000)]
* libmisc/setugid.c (setup_uid_gid): The is_console argument is no a bool.
* libmisc/setugid.c: Avoid implicit conversion of integers / pointers to booleans.
* libmisc/setugid.c: Add brackets.

16 years ago * libmisc/pam_pass.c (do_pam_passwd): The silent and
nekral-guest [Sun, 25 May 2008 23:38:05 +0000 (23:38 +0000)]
* libmisc/pam_pass.c (do_pam_passwd): The silent and
change_expired are no booleans instead of int.
* libmisc/pam_pass.c: The return value of pam_end is not checked
on purpose.

16 years agoUpdated copyright dates.
nekral-guest [Sun, 25 May 2008 23:32:41 +0000 (23:32 +0000)]
Updated copyright dates.

16 years agoUpdated copyright dates.
nekral-guest [Sun, 25 May 2008 23:31:10 +0000 (23:31 +0000)]
Updated copyright dates.

16 years ago * libmisc/getlong.c: Avoid implicit conversion of pointers / chars to booleans.
nekral-guest [Sun, 25 May 2008 23:25:33 +0000 (23:25 +0000)]
* libmisc/getlong.c: Avoid implicit conversion of pointers / chars to booleans.
* libmisc/getlong.c: Add brackets.

16 years ago * libmisc/valid.c: Avoid implicit conversion of pointers /chars to booleans.
nekral-guest [Sun, 25 May 2008 23:22:15 +0000 (23:22 +0000)]
* libmisc/valid.c: Avoid implicit conversion of pointers /chars to booleans.
* libmisc/valid.c: Add brackets.

16 years ago * libmisc/yesno.c: yes_or_no returns a bool instead of int.
nekral-guest [Sun, 25 May 2008 23:01:14 +0000 (23:01 +0000)]
* libmisc/yesno.c: yes_or_no returns a bool instead of int.
* libmisc/yesno.c: Avoid implicit conversion of pointers to booleans.
* libmisc/yesno.c: The return value of fflush is not checked on purpose.

16 years ago(failcheck): The failed argument is a bool.
nekral-guest [Sun, 25 May 2008 22:54:20 +0000 (22:54 +0000)]
(failcheck): The failed argument is a bool.

16 years agoAvoid implicit conversion of integers to booleans.
nekral-guest [Sun, 25 May 2008 22:51:46 +0000 (22:51 +0000)]
Avoid implicit conversion of integers to booleans.

16 years ago * libmisc/rlogin.c: Avoid assignments in comparisons.
nekral-guest [Sun, 25 May 2008 22:49:41 +0000 (22:49 +0000)]
* libmisc/rlogin.c: Avoid assignments in comparisons.
* libmisc/rlogin.c: Avoid implicit conversion of integers to booleans.
* libmisc/rlogin.c: Add brackets.

16 years ago * libmisc/failure.c (failcheck): The failed argument is a bool.
nekral-guest [Sun, 25 May 2008 22:44:44 +0000 (22:44 +0000)]
* libmisc/failure.c (failcheck): The failed argument is a bool.
* libmisc/failure.c (too_many_failures): too_many_failures returns
a bool.
* libmisc/failure.c: Add notes about unchecked return values.
* libmisc/failure.c: Avoid assignments in comparisons.
* libmisc/failure.c: Add brackets.