g_dir_open: added g_return_val_if_fail() to prevent us from calling

2002-02-08  Michael Natterer  <mitch@gimp.org>

	* glib/gdir.c: g_dir_open: added g_return_val_if_fail() to prevent
	us from calling opendir(NULL) (which simply crashes).
This commit is contained in:
Michael Natterer 2002-02-08 17:08:22 +00:00 committed by Michael Natterer
parent 8db64a1a96
commit 147ca6cbc8
9 changed files with 45 additions and 1 deletions

View File

@ -1,3 +1,8 @@
2002-02-08 Michael Natterer <mitch@gimp.org>
* glib/gdir.c: g_dir_open: added g_return_val_if_fail() to prevent
us from calling opendir(NULL) (which simply crashes).
2002-02-08 Sebastian Wilhelmi <wilhelmi@ira.uka.de>
* glib/gfileutils.c (g_file_test): Extended documentation.

View File

@ -1,3 +1,8 @@
2002-02-08 Michael Natterer <mitch@gimp.org>
* glib/gdir.c: g_dir_open: added g_return_val_if_fail() to prevent
us from calling opendir(NULL) (which simply crashes).
2002-02-08 Sebastian Wilhelmi <wilhelmi@ira.uka.de>
* glib/gfileutils.c (g_file_test): Extended documentation.

View File

@ -1,3 +1,8 @@
2002-02-08 Michael Natterer <mitch@gimp.org>
* glib/gdir.c: g_dir_open: added g_return_val_if_fail() to prevent
us from calling opendir(NULL) (which simply crashes).
2002-02-08 Sebastian Wilhelmi <wilhelmi@ira.uka.de>
* glib/gfileutils.c (g_file_test): Extended documentation.

View File

@ -1,3 +1,8 @@
2002-02-08 Michael Natterer <mitch@gimp.org>
* glib/gdir.c: g_dir_open: added g_return_val_if_fail() to prevent
us from calling opendir(NULL) (which simply crashes).
2002-02-08 Sebastian Wilhelmi <wilhelmi@ira.uka.de>
* glib/gfileutils.c (g_file_test): Extended documentation.

View File

@ -1,3 +1,8 @@
2002-02-08 Michael Natterer <mitch@gimp.org>
* glib/gdir.c: g_dir_open: added g_return_val_if_fail() to prevent
us from calling opendir(NULL) (which simply crashes).
2002-02-08 Sebastian Wilhelmi <wilhelmi@ira.uka.de>
* glib/gfileutils.c (g_file_test): Extended documentation.

View File

@ -1,3 +1,8 @@
2002-02-08 Michael Natterer <mitch@gimp.org>
* glib/gdir.c: g_dir_open: added g_return_val_if_fail() to prevent
us from calling opendir(NULL) (which simply crashes).
2002-02-08 Sebastian Wilhelmi <wilhelmi@ira.uka.de>
* glib/gfileutils.c (g_file_test): Extended documentation.

View File

@ -1,3 +1,8 @@
2002-02-08 Michael Natterer <mitch@gimp.org>
* glib/gdir.c: g_dir_open: added g_return_val_if_fail() to prevent
us from calling opendir(NULL) (which simply crashes).
2002-02-08 Sebastian Wilhelmi <wilhelmi@ira.uka.de>
* glib/gfileutils.c (g_file_test): Extended documentation.

View File

@ -1,3 +1,8 @@
2002-02-08 Michael Natterer <mitch@gimp.org>
* glib/gdir.c: g_dir_open: added g_return_val_if_fail() to prevent
us from calling opendir(NULL) (which simply crashes).
2002-02-08 Sebastian Wilhelmi <wilhelmi@ira.uka.de>
* glib/gfileutils.c (g_file_test): Extended documentation.

View File

@ -61,7 +61,11 @@ g_dir_open (const gchar *path,
guint flags,
GError **error)
{
GDir *dir = g_new (GDir, 1);
GDir *dir;
g_return_val_if_fail (path != NULL, NULL);
dir = g_new (GDir, 1);
dir->dir = opendir (path);