> I just noticed that if the last line in a file doesn't have a \n
> character at the end, wc doesn't count that line. Is this the intended
> behavior or a bug?

Yes that is the intended behavior.  The wc program counts the number
of newlines in a file.  If a file does not end in a newline then it
won't get added to the count of newline characters.  Check out the man
page for wc, the info page for wc or the online standards pages.

  http://www.UNIX-systems.org/single_UNIX_specification_v2/xcu/wc.html

Bob

_______________________________________________
Bug-textutils mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/bug-textutils

Reply via email to