diff options
author | Havoc Pennington <hp@redhat.com> | 2003-03-26 03:58:11 +0000 |
---|---|---|
committer | Havoc Pennington <hp@redhat.com> | 2003-03-26 03:58:11 +0000 |
commit | 90ed1d84588a84697051e643175452c50d682ece (patch) | |
tree | a8ee3ecb05c584194d5c74e98038c24e5fdabe9b /bus/desktop-file.c | |
parent | 17e82f5728d3fc8abd41c816b1c34c506339c7a7 (diff) |
2003-03-25 Havoc Pennington <hp@redhat.com>
* throughout - add more _DBUS_ASSERT_ERROR_IS_CLEAR
* configure.in: add --with-xml option to specify XML library,
right now only libxml is supported.
* bus/config-loader-libxml.c, config-parser.c: sync some minor
nonworking code between home and work, still just stubs
Diffstat (limited to 'bus/desktop-file.c')
-rw-r--r-- | bus/desktop-file.c | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/bus/desktop-file.c b/bus/desktop-file.c index f45a997e..13b709d2 100644 --- a/bus/desktop-file.c +++ b/bus/desktop-file.c @@ -180,6 +180,8 @@ unescape_string (BusDesktopFileParser *parser, DBusError *error) { char *retval, *q; + + _DBUS_ASSERT_ERROR_IS_CLEAR (error); /* len + 1 is enough, because unescaping never makes the * string longer @@ -389,6 +391,8 @@ parse_section_start (BusDesktopFileParser *parser, DBusError *error) { int line_end; char *section_name; + + _DBUS_ASSERT_ERROR_IS_CLEAR (error); if (!_dbus_string_find (&parser->data, parser->pos, "\n", &line_end)) line_end = parser->len; @@ -447,6 +451,8 @@ parse_key_value (BusDesktopFileParser *parser, DBusError *error) char *value, *tmp; DBusString key; BusDesktopFileLine *line; + + _DBUS_ASSERT_ERROR_IS_CLEAR (error); if (!_dbus_string_find (&parser->data, parser->pos, "\n", &line_end)) line_end = parser->len; @@ -549,7 +555,9 @@ report_error (BusDesktopFileParser *parser, DBusError *error) { const char *section_name = NULL; - + + _DBUS_ASSERT_ERROR_IS_CLEAR (error); + if (parser->current_section != -1) section_name = parser->desktop_file->sections[parser->current_section].section_name; @@ -589,6 +597,8 @@ bus_desktop_file_load (DBusString *filename, DBusString str; BusDesktopFileParser parser; DBusStat sb; + + _DBUS_ASSERT_ERROR_IS_CLEAR (error); /* Clearly there's a race here, but it's just to make it unlikely * that we do something silly, we still handle doing it below. |