aboutsummaryrefslogtreecommitdiffhomepage
path: root/common.h
diff options
context:
space:
mode:
authorGravatar axel <axel@liljencrantz.se>2006-10-20 01:19:47 +1000
committerGravatar axel <axel@liljencrantz.se>2006-10-20 01:19:47 +1000
commit2d05b1c1b4cf51df30903a24d1d7944aa1b8eeb7 (patch)
tree8f447868c883184e67770e41e02c76321c38c038 /common.h
parentea998b03f236be4e8af73474d994af5bbc4b0287 (diff)
Add compiler warnings for some common incorrect usage of functions, such as forgetting to cast null pointers to variadic functions
darcs-hash:20061019151947-ac50b-4043638a7a830fa80fd918f92365f5afe3ff208a.gz
Diffstat (limited to 'common.h')
-rw-r--r--common.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/common.h b/common.h
index d9c7cc27..2cefd584 100644
--- a/common.h
+++ b/common.h
@@ -106,6 +106,7 @@ extern wchar_t *program_name;
*/
#define N_(wstr) wstr
+
/**
Take an array_list_t containing wide strings and converts them to a
single null-terminated wchar_t **. The array is allocated using
@@ -193,7 +194,7 @@ wchar_t *wcsdupcat( const wchar_t *a, const wchar_t *b );
Returns a newly allocated concatenation of the specified wide
character strings. The last argument must be a null pointer.
*/
-wchar_t *wcsdupcat2( const wchar_t *a, ... );
+__sentinel wchar_t *wcsdupcat2( const wchar_t *a, ... );
/**
Test if the given string is a valid variable name
@@ -256,7 +257,7 @@ const wchar_t *wsetlocale( int category, const wchar_t *locale );
\return zero is needle is not found, of if needle is null, non-zero otherwise
*/
-int contains_str( const wchar_t *needle, ... );
+__sentinel int contains_str( const wchar_t *needle, ... );
/**
Call read while blocking the SIGCHLD signal. Should only be called