mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-09-27 17:52:58 +02:00
add simple test for g_path_get_basename().
Tue Sep 18 18:19:33 2001 Tim Janik <timj@gtk.org> * tests/testglib.c: add simple test for g_path_get_basename(). * glib/gfileutils.c (g_file_open_tmp): * glib/gstrfuncs.c (g_strerror): scratch erroneous usages of "illegal".
This commit is contained in:
@@ -1,3 +1,11 @@
|
|||||||
|
Tue Sep 18 18:19:33 2001 Tim Janik <timj@gtk.org>
|
||||||
|
|
||||||
|
* tests/testglib.c: add simple test for g_path_get_basename().
|
||||||
|
|
||||||
|
* glib/gfileutils.c (g_file_open_tmp):
|
||||||
|
* glib/gstrfuncs.c (g_strerror): scratch erroneous usages
|
||||||
|
of "illegal".
|
||||||
|
|
||||||
2001-09-18 Tor Lillqvist <tml@iki.fi>
|
2001-09-18 Tor Lillqvist <tml@iki.fi>
|
||||||
|
|
||||||
* glib/gmain.c
|
* glib/gmain.c
|
||||||
|
@@ -1,3 +1,11 @@
|
|||||||
|
Tue Sep 18 18:19:33 2001 Tim Janik <timj@gtk.org>
|
||||||
|
|
||||||
|
* tests/testglib.c: add simple test for g_path_get_basename().
|
||||||
|
|
||||||
|
* glib/gfileutils.c (g_file_open_tmp):
|
||||||
|
* glib/gstrfuncs.c (g_strerror): scratch erroneous usages
|
||||||
|
of "illegal".
|
||||||
|
|
||||||
2001-09-18 Tor Lillqvist <tml@iki.fi>
|
2001-09-18 Tor Lillqvist <tml@iki.fi>
|
||||||
|
|
||||||
* glib/gmain.c
|
* glib/gmain.c
|
||||||
|
@@ -1,3 +1,11 @@
|
|||||||
|
Tue Sep 18 18:19:33 2001 Tim Janik <timj@gtk.org>
|
||||||
|
|
||||||
|
* tests/testglib.c: add simple test for g_path_get_basename().
|
||||||
|
|
||||||
|
* glib/gfileutils.c (g_file_open_tmp):
|
||||||
|
* glib/gstrfuncs.c (g_strerror): scratch erroneous usages
|
||||||
|
of "illegal".
|
||||||
|
|
||||||
2001-09-18 Tor Lillqvist <tml@iki.fi>
|
2001-09-18 Tor Lillqvist <tml@iki.fi>
|
||||||
|
|
||||||
* glib/gmain.c
|
* glib/gmain.c
|
||||||
|
@@ -1,3 +1,11 @@
|
|||||||
|
Tue Sep 18 18:19:33 2001 Tim Janik <timj@gtk.org>
|
||||||
|
|
||||||
|
* tests/testglib.c: add simple test for g_path_get_basename().
|
||||||
|
|
||||||
|
* glib/gfileutils.c (g_file_open_tmp):
|
||||||
|
* glib/gstrfuncs.c (g_strerror): scratch erroneous usages
|
||||||
|
of "illegal".
|
||||||
|
|
||||||
2001-09-18 Tor Lillqvist <tml@iki.fi>
|
2001-09-18 Tor Lillqvist <tml@iki.fi>
|
||||||
|
|
||||||
* glib/gmain.c
|
* glib/gmain.c
|
||||||
|
@@ -1,3 +1,11 @@
|
|||||||
|
Tue Sep 18 18:19:33 2001 Tim Janik <timj@gtk.org>
|
||||||
|
|
||||||
|
* tests/testglib.c: add simple test for g_path_get_basename().
|
||||||
|
|
||||||
|
* glib/gfileutils.c (g_file_open_tmp):
|
||||||
|
* glib/gstrfuncs.c (g_strerror): scratch erroneous usages
|
||||||
|
of "illegal".
|
||||||
|
|
||||||
2001-09-18 Tor Lillqvist <tml@iki.fi>
|
2001-09-18 Tor Lillqvist <tml@iki.fi>
|
||||||
|
|
||||||
* glib/gmain.c
|
* glib/gmain.c
|
||||||
|
@@ -1,3 +1,11 @@
|
|||||||
|
Tue Sep 18 18:19:33 2001 Tim Janik <timj@gtk.org>
|
||||||
|
|
||||||
|
* tests/testglib.c: add simple test for g_path_get_basename().
|
||||||
|
|
||||||
|
* glib/gfileutils.c (g_file_open_tmp):
|
||||||
|
* glib/gstrfuncs.c (g_strerror): scratch erroneous usages
|
||||||
|
of "illegal".
|
||||||
|
|
||||||
2001-09-18 Tor Lillqvist <tml@iki.fi>
|
2001-09-18 Tor Lillqvist <tml@iki.fi>
|
||||||
|
|
||||||
* glib/gmain.c
|
* glib/gmain.c
|
||||||
|
@@ -1,3 +1,11 @@
|
|||||||
|
Tue Sep 18 18:19:33 2001 Tim Janik <timj@gtk.org>
|
||||||
|
|
||||||
|
* tests/testglib.c: add simple test for g_path_get_basename().
|
||||||
|
|
||||||
|
* glib/gfileutils.c (g_file_open_tmp):
|
||||||
|
* glib/gstrfuncs.c (g_strerror): scratch erroneous usages
|
||||||
|
of "illegal".
|
||||||
|
|
||||||
2001-09-18 Tor Lillqvist <tml@iki.fi>
|
2001-09-18 Tor Lillqvist <tml@iki.fi>
|
||||||
|
|
||||||
* glib/gmain.c
|
* glib/gmain.c
|
||||||
|
@@ -1,3 +1,11 @@
|
|||||||
|
Tue Sep 18 18:19:33 2001 Tim Janik <timj@gtk.org>
|
||||||
|
|
||||||
|
* tests/testglib.c: add simple test for g_path_get_basename().
|
||||||
|
|
||||||
|
* glib/gfileutils.c (g_file_open_tmp):
|
||||||
|
* glib/gstrfuncs.c (g_strerror): scratch erroneous usages
|
||||||
|
of "illegal".
|
||||||
|
|
||||||
2001-09-18 Tor Lillqvist <tml@iki.fi>
|
2001-09-18 Tor Lillqvist <tml@iki.fi>
|
||||||
|
|
||||||
* glib/gmain.c
|
* glib/gmain.c
|
||||||
|
@@ -533,6 +533,7 @@ generic way.
|
|||||||
</para>
|
</para>
|
||||||
|
|
||||||
@channel:
|
@channel:
|
||||||
|
@length:
|
||||||
@Returns:
|
@Returns:
|
||||||
|
|
||||||
|
|
||||||
@@ -543,6 +544,7 @@ generic way.
|
|||||||
|
|
||||||
@channel:
|
@channel:
|
||||||
@line_term:
|
@line_term:
|
||||||
|
@length:
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### FUNCTION g_io_channel_get_buffered ##### -->
|
<!-- ##### FUNCTION g_io_channel_get_buffered ##### -->
|
||||||
|
@@ -652,7 +652,7 @@ g_file_open_tmp (const char *tmpl,
|
|||||||
g_set_error (error,
|
g_set_error (error,
|
||||||
G_FILE_ERROR,
|
G_FILE_ERROR,
|
||||||
G_FILE_ERROR_FAILED,
|
G_FILE_ERROR_FAILED,
|
||||||
_("Template '%s' illegal, should not contain a '%s'"),
|
_("Template '%s' invalid, should not contain a '%s'"),
|
||||||
tmpl, G_DIR_SEPARATOR_S);
|
tmpl, G_DIR_SEPARATOR_S);
|
||||||
|
|
||||||
return -1;
|
return -1;
|
||||||
|
@@ -435,7 +435,7 @@ g_strerror (gint errnum)
|
|||||||
case EISCONN: return "socket is already connected";
|
case EISCONN: return "socket is already connected";
|
||||||
#endif
|
#endif
|
||||||
#ifdef EISDIR
|
#ifdef EISDIR
|
||||||
case EISDIR: return "illegal operation on a directory";
|
case EISDIR: return "is a directory";
|
||||||
#endif
|
#endif
|
||||||
#ifdef EISNAME
|
#ifdef EISNAME
|
||||||
case EISNAM: return "is a name file";
|
case EISNAM: return "is a name file";
|
||||||
|
@@ -440,6 +440,15 @@ main (int argc,
|
|||||||
#endif /* G_HAVE_GINT64 */
|
#endif /* G_HAVE_GINT64 */
|
||||||
g_print ("\n");
|
g_print ("\n");
|
||||||
|
|
||||||
|
g_print ("checking g_path_get_basename()...");
|
||||||
|
string = g_path_get_basename ("/foo/dir/");
|
||||||
|
g_assert (strcmp (string, "dir") == 0);
|
||||||
|
g_free (string);
|
||||||
|
string = g_path_get_basename ("/foo/file");
|
||||||
|
g_assert (strcmp (string, "file") == 0);
|
||||||
|
g_free (string);
|
||||||
|
g_print ("ok\n");
|
||||||
|
|
||||||
g_print ("checking g_path_get_dirname()...");
|
g_print ("checking g_path_get_dirname()...");
|
||||||
for (i = 0; i < n_dirname_checks; i++)
|
for (i = 0; i < n_dirname_checks; i++)
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user