~ubuntu-branches/ubuntu/natty/geany/natty

« back to all changes in this revision

Viewing changes to tagmanager/tm_workspace.c

  • Committer: Bazaar Package Importer
  • Author(s): Chow Loong Jin
  • Date: 2010-08-07 03:23:12 UTC
  • mfrom: (1.4.3 upstream)
  • mto: This revision was merged to the branch mainline in revision 22.
  • Revision ID: james.westby@ubuntu.com-20100807032312-ot70ac9d50cn79we
Tags: upstream-0.19
ImportĀ upstreamĀ versionĀ 0.19

Show diffs side-by-side

added added

removed removed

Lines of Context:
147
147
        TMTag *tag;
148
148
        gboolean format_pipe = FALSE;
149
149
 
 
150
        if (NULL == theWorkspace)
 
151
                return FALSE;
150
152
        if (NULL == (fp = g_fopen(tags_file, "r")))
151
153
                return FALSE;
152
 
        if (NULL == theWorkspace)
153
 
                return FALSE;
154
154
        if (NULL == theWorkspace->global_tags)
155
155
                theWorkspace->global_tags = g_ptr_array_new();
156
156
        if ((NULL == fgets((gchar*) buf, BUFSIZ, fp)) || ('\0' == *buf))
 
157
        {
 
158
                fclose(fp);
157
159
                return FALSE; /* early out on error */
 
160
        }
158
161
        else
159
162
        {       /* We read the first line for the format specification. */
160
163
                if (buf[0] == '#' && strstr((gchar*) buf, "format=pipe") != NULL)
281
284
#endif
282
285
 
283
286
        if (NULL == theWorkspace || NULL == (fp = g_fopen(temp_file, "w")))
 
287
        {
 
288
                g_free(temp_file);
 
289
                g_free(temp_file2);
284
290
                return FALSE;
 
291
        }
285
292
 
286
293
        includes_files_hash = g_hash_table_new_full (tm_file_inode_hash,
287
294
                                                                                                 g_direct_equal,