[Pkg-shadow-commits] r2714 - in upstream/trunk: . libmisc
Nicolas FRANÇOIS
nekral-guest at alioth.debian.org
Mon Apr 20 11:31:05 UTC 2009
Author: nekral-guest
Date: 2009-04-20 11:31:05 +0000 (Mon, 20 Apr 2009)
New Revision: 2714
Modified:
upstream/trunk/ChangeLog
upstream/trunk/libmisc/ttytype.c
Log:
* libmisc/ttytype.c: Add brackets and parenthesis.
* libmisc/ttytype.c: Avoid assignments in comparisons.
Modified: upstream/trunk/ChangeLog
===================================================================
--- upstream/trunk/ChangeLog 2009-04-20 11:29:17 UTC (rev 2713)
+++ upstream/trunk/ChangeLog 2009-04-20 11:31:05 UTC (rev 2714)
@@ -1,5 +1,10 @@
2009-04-20 Nicolas François <nicolas.francois at centraliens.net>
+ * libmisc/ttytype.c: Add brackets and parenthesis.
+ * libmisc/ttytype.c: Avoid assignments in comparisons.
+
+2009-04-20 Nicolas François <nicolas.francois at centraliens.net>
+
* lib/pwio.c, lib/shadowio.c, lib/groupio.c, lib/sgroupio.c: Fill
the password fields with zeros before they are freed.
Modified: upstream/trunk/libmisc/ttytype.c
===================================================================
--- upstream/trunk/libmisc/ttytype.c 2009-04-20 11:29:17 UTC (rev 2713)
+++ upstream/trunk/libmisc/ttytype.c 2009-04-20 11:31:05 UTC (rev 2714)
@@ -50,12 +50,16 @@
char type[BUFSIZ];
char port[BUFSIZ];
- if (getenv ("TERM"))
+ if (getenv ("TERM") != NULL) {
return;
- if ((typefile = getdef_str ("TTYTYPE_FILE")) == NULL)
+ }
+ typefile = getdef_str ("TTYTYPE_FILE");
+ if (NULL == typefile) {
return;
- if (access (typefile, F_OK) != 0)
+ }
+ if (access (typefile, F_OK) != 0) {
return;
+ }
fp = fopen (typefile, "r");
if (NULL == fp) {
More information about the Pkg-shadow-commits
mailing list