maint: update all copyright year number ranges
[platform/upstream/coreutils.git] / src / sum.c
index f0e0cc0..9ebcc42 100644 (file)
--- a/src/sum.c
+++ b/src/sum.c
@@ -1,6 +1,5 @@
 /* sum -- checksum and count the blocks in a file
-   Copyright (C) 86, 89, 91, 1995-2002, 2004, 2005,
-   2008-2009 Free Software Foundation, Inc.
+   Copyright (C) 1986-2013 Free Software Foundation, Inc.
 
    This program is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
 #include <getopt.h>
 #include "system.h"
 #include "error.h"
+#include "fadvise.h"
 #include "human.h"
 #include "safe-read.h"
 #include "xfreopen.h"
 
-/* The official name of this program (e.g., no `g' prefix).  */
+/* The official name of this program (e.g., no 'g' prefix).  */
 #define PROGRAM_NAME "sum"
 
 #define AUTHORS \
@@ -52,8 +52,7 @@ void
 usage (int status)
 {
   if (status != EXIT_SUCCESS)
-    fprintf (stderr, _("Try `%s --help' for more information.\n"),
-             program_name);
+    emit_try_help ();
   else
     {
       printf (_("\
@@ -110,6 +109,8 @@ bsd_sum_file (const char *file, int print_name)
         }
     }
 
+  fadvise (fp, FADVISE_SEQUENTIAL);
+
   while ((ch = getc (fp)) != EOF)
     {
       total_bytes++;