[2.5] cmdline_read_proc strangeness?

From: Oleg Drokin (green@namesys.com)
Date: Tue May 20 2003 - 06:40:10 EST


Hello!

    There is a bit of strange code in fs/proc/proc_misc.c::cmdline_read_proc()

        int len;

        len = sprintf(page, "%s\n", saved_command_line);
        len = strlen(page);

    Why do we need the strlen() here? It looks like pure overhead to me.
    Am I missing something obvious?

Bye,
    Oleg
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Fri May 23 2003 - 22:00:40 EST