Commit Graph

799 Commits

Author SHA1 Message Date
nekral-guest
e43c3aed67 Add brackets and parenthesis. 2008-06-09 20:32:17 +00:00
nekral-guest
6aa98c17bd * 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.
2008-06-09 20:30:34 +00:00
nekral-guest
a9f1ce0db1 * 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.
2008-06-09 20:17:48 +00:00
nekral-guest
d48973bbc8 * 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.
2008-06-09 20:09:38 +00:00
nekral-guest
3879f07fa8 * 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().
2008-06-09 20:05:13 +00:00
nekral-guest
3ea7f76c17 * 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.
2008-06-09 20:02:46 +00:00
nekral-guest
827f8882bc * 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().
2008-06-09 19:46:11 +00:00
nekral-guest
24a7015f64 * 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.
2008-06-09 19:43:22 +00:00
nekral-guest
2a267ca05f * 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.
2008-06-09 19:36:08 +00:00
nekral-guest
e41460cae5 * 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().
2008-06-09 19:26:19 +00:00
nekral-guest
5e2b49dad4 * src/grpck.c: Use a bool when possible instead of int integers.
* src/grpck.c: Ignore return value of setlocale(),
	bindtextdomain(), and textdomain().
2008-06-09 19:20:00 +00:00
nekral-guest
5038f6687b * 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().
2008-06-09 19:15:27 +00:00
nekral-guest
8b98a2e829 * 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.
2008-06-09 19:10:44 +00:00
nekral-guest
46466a8fcc * 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.
2008-06-09 18:35:32 +00:00
nekral-guest
4e0d734598 * 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.
2008-06-09 18:23:23 +00:00
nekral-guest
8cfe8db1fb * libmisc/list.c: Change is_on_list() prototype to return a bool. 2008-06-09 18:13:52 +00:00
nekral-guest
5ae74603da * 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).
2008-06-09 18:13:09 +00:00
nekral-guest
747664ad4f * 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.
2008-06-09 18:11:20 +00:00
nekral-guest
9e31065b5e * 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.
2008-05-26 09:39:29 +00:00
nekral-guest
004fb5f9c2 Avoid assignments in comparisons.
Add note about possible bug.
2008-05-26 09:22:44 +00:00
nekral-guest
da62edb4e0 Do not check twice if fields[2] and fields[3] are not empty. 2008-05-26 09:17:17 +00:00
nekral-guest
adc4729ffa * 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.
2008-05-26 09:15:02 +00:00
nekral-guest
64d0313c5b * Avoid implicit conversion of pointers to booleans.
* Add parenthesis.
2008-05-26 09:12:34 +00:00
nekral-guest
94b414861d * libmisc/getdate.y: abbrev is a bool.
* libmisc/getdate.y: Avoid implicit conversion of pointers / chars / integers to booleans.
2008-05-26 08:59:54 +00:00
nekral-guest
9305161183 * lib/prototypes.h: Fix prototypes according to earlier changes (usage of the bool type).
* lib/prototypes.h: Add the arguments' name to the prototypes.
2008-05-26 08:56:34 +00:00
nekral-guest
297fa24b90 Add protection against multiple inclusions. 2008-05-26 08:53:56 +00:00
nekral-guest
3ca3362283 Indicate that defines.h is included for the definition of the "bool" type. 2008-05-26 08:52:34 +00:00
nekral-guest
4f38c8d201 The changed, isopen, locked, and readonly fields of the db are booleans. 2008-05-26 08:51:45 +00:00
nekral-guest
964f68630a * lib/pwio.h: Add protection against multiple inclusions.
* lib/pwio.c: The changed, isopen, locked, and readonly fields of the db are booleans.
2008-05-26 08:49:44 +00:00
nekral-guest
caed1add3a * 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.
2008-05-26 08:46:41 +00:00
nekral-guest
77020623ed * lib/shadowio.h, lib/shadowio.c: spw_file_present returns a bool.
* lib/shadowio.h: Add protection against multiple inclusions.
2008-05-26 08:45:34 +00:00
nekral-guest
d264017684 * 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.
2008-05-26 08:43:50 +00:00
nekral-guest
383ea561f8 * 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.
2008-05-26 08:40:04 +00:00
nekral-guest
ef5e803875 Add protection against multiple inclusion 2008-05-26 08:35:13 +00:00
nekral-guest
22de221c21 The changed, isopen, locked, and readonly fields of the db are booleans. 2008-05-26 08:34:04 +00:00
nekral-guest
6f88bcf581 * lib/sgetgrent.c: implicit conversion of pointers / chars to booleans.
* lib/sgetgrent.c: Avoid assignments in comparisons.
	* lib/sgetgrent.c: Add brackets.
2008-05-26 08:31:14 +00:00
nekral-guest
6ce26e12f5 * lib/encrypt.c: Avoid implicit conversion of pointers to booleans.
* lib/encrypt.c: Add parenthesis.
2008-05-26 01:07:13 +00:00
nekral-guest
09869159f7 * 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).
2008-05-26 01:05:04 +00:00
nekral-guest
14839257ac * lib/fputsx.c: Add brackets.
* lib/fputsx.c: Avoid assignments in comparisons.
	* lib/fputsx.c: Avoid implicit conversion of pointers / integers / chars to booleans.
2008-05-26 00:59:42 +00:00
nekral-guest
f16c6bd7dd * 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.
2008-05-26 00:46:25 +00:00
nekral-guest
a24aff2148 checkutmp is implemented twice. I only changed the second one. Now fix the
first one.
2008-05-26 00:26:33 +00:00
nekral-guest
fc6d8e933b * 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.
2008-05-26 00:14:10 +00:00
nekral-guest
c6364944d4 * 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.
2008-05-26 00:09:24 +00:00
nekral-guest
70ef747a56 Updated copyright dates. 2008-05-26 00:04:30 +00:00
nekral-guest
3d7aa44c8e * 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.
2008-05-26 00:02:15 +00:00
nekral-guest
c249832df1 * libmisc/mail.c: Avoid implicit conversion of pointers to booleans.
* libmisc/mail.c: Avoid assignments in comparisons.
2008-05-25 23:59:05 +00:00
nekral-guest
3169455653 * 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.
2008-05-25 23:57:41 +00:00
nekral-guest
f7122499a6 Avoid implicit conversion of chars to booleans. 2008-05-25 23:50:03 +00:00
nekral-guest
cc7ac94641 selinux_checked, selinux_enabled, and set_orig are now booleans. 2008-05-25 23:45:21 +00:00
nekral-guest
7f9dfde0dc * 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.
2008-05-25 23:42:39 +00:00