Re: [gnome-db] Fix for #153292: Unlocalized Items in Mergeant Database



On Apr 12, 2005 2:33 PM, Jorge Bernal <koke amedias org> wrote:
> I've done this little patch, which fixes #153292, I'd like
> you to review it and apply. I'm not sure if it's the Right
> Way :)
> 
> Thanks,
>     Koke
> 
> PS: The patch is also attached to the bug report.
> 
> Index: libgda/gda-config.c
> ===================================================================
> RCS file: /cvs/gnome/libgda/libgda/gda-config.c,v
> retrieving revision 1.62
> diff -u -3 -p -r1.62 gda-config.c
> --- libgda/gda-config.c 23 Jan 2005 18:35:20 -0000      1.62
> +++ libgda/gda-config.c 11 Apr 2005 09:46:22 -0000
> @@ -1372,7 +1372,6 @@ gda_config_get_data_source_list (void)
>                 GdaDataSourceInfo *info;
> 
>                 info = g_new0 (GdaDataSourceInfo, 1);
> -               info->name = g_strdup ((const gchar *) l->data);
> 
>                 /* get the provider */
>                 tmp = g_strdup_printf ("%s/%s/Provider", GDA_CONFIG_SECTION_DATASOURCES, (char *) l->data);
> @@ -1399,6 +1398,12 @@ gda_config_get_data_source_list (void)
>                 info->password = gda_config_get_string (tmp);
>                 g_free (tmp);
> 
> +               if (!g_strncmp ("Default", l->data, 7)) {
> +                   /* This is the default data source name */
> +                   info->name = g_strdup (_("Default"));
> +               } else {
> +                   info->name = g_strdup ((const gchar *) l->data);
> +               }
>                 list = g_list_append (list, info);
>         }
> 

Thanks!

Vivien



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]