Add braces to eliminate an ambiguous else warning.

Thu Jan 21 12:40:11 EST 1999  Jeff Garzik  <jgarzik@pobox.com>

        * gmodule/gmodule-dl.c (_g_module_build_path):
        Add braces to eliminate an ambiguous else warning.

        * tests/{Makefile.am, string-test.c, strfunc-test.c}:
        Separate string and strfunc tests, working towards goal of
        having separate test for each of the GLib modules.
        Add a couple GString length tests.
This commit is contained in:
EST 1999 Jeff Garzik
1999-01-21 18:07:20 +00:00
committed by Jeff Garzik
parent 55fa3d1112
commit dc22ea7760
13 changed files with 184 additions and 41 deletions

View File

@@ -125,12 +125,12 @@ static gchar*
_g_module_build_path (const gchar *directory,
const gchar *module_name)
{
if (directory && *directory)
if (directory && *directory) {
if (strncmp (module_name, "lib", 3) == 0)
return g_strconcat (directory, "/", module_name, NULL);
else
return g_strconcat (directory, "/lib", module_name, ".so", NULL);
else if (strncmp (module_name, "lib", 3) == 0)
} else if (strncmp (module_name, "lib", 3) == 0)
return g_strdup (module_name);
else
return g_strconcat ("lib", module_name, ".so", NULL);