about summary refs log tree commit diff
path: root/locale/weight.h
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>1999-08-18 00:23:27 +0000
committerUlrich Drepper <drepper@redhat.com>1999-08-18 00:23:27 +0000
commit5d08d21845b284c3ad10aafec82cf85938229613 (patch)
tree5363c4eb1801f0fc1a8d7059722743bbf532597b /locale/weight.h
parent23f7e58e0da975e973c69b980e0facb0e682c664 (diff)
downloadglibc-5d08d21845b284c3ad10aafec82cf85938229613.tar.gz
glibc-5d08d21845b284c3ad10aafec82cf85938229613.tar.xz
glibc-5d08d21845b284c3ad10aafec82cf85938229613.zip
Update.
1999-08-17  Ulrich Drepper  <drepper@cygnus.com>

	* locale/weight.h: Set errno if an invalid character is found.
Diffstat (limited to 'locale/weight.h')
-rw-r--r--locale/weight.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/locale/weight.h b/locale/weight.h
index 9a1911bd7a..fed84244bd 100644
--- a/locale/weight.h
+++ b/locale/weight.h
@@ -1,6 +1,6 @@
-/* Copyright (C) 1996, 1997 Free Software Foundation, Inc.
+/* Copyright (C) 1996, 1997, 1999 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
-   Written by Ulrich Drepper, <drepper@gnu.ai.mit.edu>.
+   Written by Ulrich Drepper, <drepper@cygnus.com>.
 
    The GNU C Library is free software; you can redistribute it and/or
    modify it under the terms of the GNU Library General Public License as
@@ -107,6 +107,9 @@ get_weight (const STRING_TYPE **str, weight_t *result,
 		  result->data[cnt].value = &__collate_extra[idx];
 		  idx += result->data[cnt].number;
 		}
+	      /* The Unix standard requires that a character outside
+		 the domain is signalled by setting `errno'.  */
+	      __set_errno (EINVAL);
 	      return;
 	    }
 	  slot += level_size;