~ubuntu-desktop/libindicator/ubuntu

« back to all changes in this revision

Viewing changes to libindicator/indicator-object.c

  • Committer: Sebastien Bacher
  • Date: 2012-03-08 20:57:54 UTC
  • mfrom: (337.1.92 ubuntu)
  • Revision ID: seb128@ubuntu.com-20120308205754-ryk2guh8b2bhlmqh
Tags: 0.4.93-0ubuntu1
releasing version 0.4.93-0ubuntu1

Show diffs side-by-side

added added

removed removed

Lines of Context:
464
464
                goto unrefandout;
465
465
        }
466
466
 
467
 
        IndicatorObjectPrivate * priv = INDICATOR_OBJECT_GET_PRIVATE(object);
468
467
        /* Now we can track the module */
469
 
        priv->module = module;
 
468
        INDICATOR_OBJECT_GET_PRIVATE(object)->module = module;
470
469
 
471
470
        return INDICATOR_OBJECT(object);
472
471
 
473
472
        /* Error, let's drop the object and return NULL.  Sad when
474
473
           this happens. */
475
474
unrefandout:
476
 
        if (object != NULL) {
477
 
                g_object_unref(object);
478
 
        }
479
 
        if (module != NULL) {
480
 
                g_object_unref(module);
481
 
        }
 
475
        g_clear_object (&object);
 
476
        g_clear_object (&module);
482
477
        g_warning("Error building IndicatorObject from file: %s", file);
483
478
        return NULL;
484
479
}