On Fri, Jul 13, 2007 at 02:21:15PM +0200, Bernhard Walle wrote: > * Karel Zak <kzak@xxxxxxxxxx> [2007-07-13 14:13]: > > > +static int read_clock_mode(void) > > > +{ > > > + FILE *fp; > > > + char linebuf[MAX_LINE]; > > > + > > > + fp = fopen(ADJTIME_PATH, "r"); > > > + if (!fp) > > > + return 0; > > > + > > .... > > > > fclose(fp); > > That would be fclose(NULL). Where's the benefit? Well, I mean that you don't close the "fd" when you successfully read third line from /etc/adjtime. See end of read_clock_mode(), there is "return 1", but not fclose(). Karel -- Karel Zak <kzak@xxxxxxxxxx> - To unsubscribe from this list: send the line "unsubscribe util-linux-ng" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html