Document that g_strdup() and g_strndup() accept NULL. (#106987, Christian
authorMatthias Clasen <maclas@gmx.de>
Tue, 27 May 2003 22:25:03 +0000 (22:25 +0000)
committerMatthias Clasen <matthiasc@src.gnome.org>
Tue, 27 May 2003 22:25:03 +0000 (22:25 +0000)
2003-05-28  Matthias Clasen  <maclas@gmx.de>

* glib/tmpl/string_utils.sgml: Document that g_strdup() and
g_strndup() accept NULL.  (#106987, Christian Biere)

docs/reference/ChangeLog
docs/reference/glib/tmpl/string_utils.sgml

index e52b143..480aa96 100644 (file)
@@ -1,3 +1,8 @@
+2003-05-28  Matthias Clasen  <maclas@gmx.de>
+
+       * glib/tmpl/string_utils.sgml: Document that g_strdup() and
+       g_strndup() accept NULL.  (#106987, Christian Biere)
+
 2003-05-12  Matthias Clasen  <maclas@gmx.de>
 
        * glib/cross.sgml: Fix a duplicate id left by copy-and-paste.
index 463b1f8..2778f4d 100644 (file)
@@ -27,11 +27,12 @@ in order to use the printf() functions.
 <!-- ##### FUNCTION g_strdup ##### -->
 <para>
 Duplicates a string.
+If @str is %NULL it returns %NULL.
 The returned string should be freed when no longer needed.
 </para>
 
 @str: the string to duplicate.
-@Returns: a newly-allocated copy of @str.
+@Returns: a newly-allocated copy of @str. 
 
 
 <!-- ##### FUNCTION g_strndup ##### -->
@@ -39,6 +40,7 @@ The returned string should be freed when no longer needed.
 Duplicates the first @n characters of a string, returning a newly-allocated
 buffer @n + 1 characters long which will always be nul-terminated.
 If @str is less than @n characters long the buffer is padded with nuls.
+If @str is %NULL it returns %NULL.
 The returned value should be freed when no longer needed.
 </para>