]> git.ipfire.org Git - thirdparty/bash.git/blobdiff - builtins/shift.def
Imported from ../bash-3.0.tar.gz.
[thirdparty/bash.git] / builtins / shift.def
index dbff0622197dd1c970133578effc7d126414570d..e20b4d54202e7eee4ab6ed4e1d7f171a4235520a 100644 (file)
@@ -1,7 +1,7 @@
 This file is shift.def, from which is created shift.c.
 It implements the builtin "shift" in Bash.
 
-Copyright (C) 1987-2002 Free Software Foundation, Inc.
+Copyright (C) 1987-2003 Free Software Foundation, Inc.
 
 This file is part of GNU Bash, the Bourne Again SHell.
 
@@ -31,6 +31,7 @@ $PRODUCES shift.c
 #endif
 
 #include "../bashansi.h"
+#include "../bashintl.h"
 
 #include "../shell.h"
 #include "common.h"
@@ -62,13 +63,13 @@ shift_builtin (list)
     return (EXECUTION_SUCCESS);
   else if (times < 0)
     {
-      sh_erange (list->word->word, "shift count");
+      sh_erange (list ? list->word->word : NULL, _("shift count"));
       return (EXECUTION_FAILURE);
     }
   else if (times > number_of_args ())
     {
       if (print_shift_error)
-       sh_erange (list->word->word, "shift count");
+       sh_erange (list ? list->word->word : NULL, _("shift count"));
       return (EXECUTION_FAILURE);
     }