Commit a04b4ac0 authored by Johannes Schmid's avatar Johannes Schmid Committed by Johannes Schmid

Fixed some errors reported by valgrind

2009-02-21  Johannes Schmid  <jhs@gnome.org>

	* libanjuta/anjuta-plugin-description.c
	(anjuta_plugin_description_new_from_string):
	* libanjuta/anjuta-plugin-handle.c (anjuta_plugin_handle_new):
	
	Fixed some errors reported by valgrind

svn path=/trunk/; revision=4777
parent 875f8411
2009-02-21 Johannes Schmid <jhs@gnome.org>
* libanjuta/anjuta-plugin-description.c
(anjuta_plugin_description_new_from_string):
* libanjuta/anjuta-plugin-handle.c (anjuta_plugin_handle_new):
Fixed some errors reported by valgrind
2009-02-20 Massimo Cora' <mcora@svn.gnome.org>
* plugins/language-support-cpp-java/plugin.c (spaces_only):
......@@ -585,24 +585,23 @@ anjuta_plugin_description_new_from_string (char *data, GError **error)
parser.line = data;
/* Put any initial comments in a NULL segment */
open_section (&parser, NULL);
while (parser.line && *parser.line)
{
if (*parser.line == '[') {
if (!parse_section_start (&parser, error))
return NULL;
} else if (is_blank_line (&parser) ||
*parser.line == '#')
parse_comment_or_blank (&parser);
else
{
if (!parse_key_value (&parser, error))
return NULL;
/* Put any initial comments in a NULL segment */
open_section (&parser, NULL);
while (parser.line != NULL && strlen(parser.line))
{
if (*parser.line == '[') {
if (!parse_section_start (&parser, error))
return NULL;
} else if (is_blank_line (&parser) ||
*parser.line == '#')
parse_comment_or_blank (&parser);
else
{
if (!parse_key_value (&parser, error))
return NULL;
}
}
}
return parser.df;
}
......
......@@ -472,8 +472,8 @@ anjuta_plugin_handle_new (const gchar *plugin_desc_path)
AnjutaPluginHandle *plugin_handle;
AnjutaPluginDescription *desc;
char *str;
gboolean *enable;
gchar *contents;
gboolean enable;
gchar *contents = NULL;
gboolean success = TRUE;
/* Load file content */
......@@ -544,8 +544,8 @@ anjuta_plugin_handle_new (const gchar *plugin_desc_path)
}
if (anjuta_plugin_description_get_boolean (desc, "Anjuta Plugin",
"UserActivatable", &enable) && !enable) {
plugin_handle->priv->user_activatable = FALSE;
"UserActivatable", &enable)) {
plugin_handle->priv->user_activatable = enable;
/*
DEBUG_PRINT ("Plugin '%s' is not user activatable",
plugin_handle->priv->name?
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment