summary refs log tree commit diff
path: root/iconv/strtab.c
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@gmail.com>2012-01-08 21:19:43 -0500
committerUlrich Drepper <drepper@gmail.com>2012-01-08 21:19:43 -0500
commitec09c1c410d40386ec3e5d2d82fc5c378b4b2681 (patch)
tree2189714f7efcfc502ddef885c7c1d541eae6684c /iconv/strtab.c
parentaebae0537dcb408100b88c6b7647a7e858c43237 (diff)
downloadglibc-ec09c1c410d40386ec3e5d2d82fc5c378b4b2681.tar.gz
glibc-ec09c1c410d40386ec3e5d2d82fc5c378b4b2681.tar.xz
glibc-ec09c1c410d40386ec3e5d2d82fc5c378b4b2681.zip
Optimize xmalloc, xcalloc, xrealloc, and xstrdup
Add alloc_size attribute and apply consistently the malloc attribute
to xmalloc, xcalloc, xrealloc, and xstrdup.
Diffstat (limited to 'iconv/strtab.c')
-rw-r--r--iconv/strtab.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/iconv/strtab.c b/iconv/strtab.c
index 4a8f29a675..37b9077276 100644
--- a/iconv/strtab.c
+++ b/iconv/strtab.c
@@ -1,5 +1,5 @@
 /* C string table handling.
-   Copyright (C) 2000, 2001, 2005 Free Software Foundation, Inc.
+   Copyright (C) 2000, 2001, 2005, 2012 Free Software Foundation, Inc.
    Written by Ulrich Drepper <drepper@redhat.com>, 2000.
 
    This program is free software; you can redistribute it and/or modify
@@ -66,7 +66,8 @@ struct Strtab
 static size_t ps;
 
 
-extern void *xmalloc (size_t n) __attribute_malloc__;
+extern void *xmalloc (size_t n)
+  __attribute_malloc__ __attribute_alloc_size (1);
 
 /* Prototypes for our functions that are used from iconvconfig.c.  If
    you change these, change also iconvconfig.c.  */