Skip to content
Snippets Groups Projects

consistent g_autoptr usage

Merged Evangelos Ribeiro Tzaras requested to merge (removed):wip/g_autoptr into master
7 files
+ 17
19
Compare changes
  • Side-by-side
  • Inline
Files
7
+ 6
8
@@ -75,7 +75,7 @@ handle_local_options (GApplication *application,
GVariantDict *options)
{
gboolean ok;
g_autoptr(GError) error = NULL;
g_autoptr (GError) error = NULL;
const gchar *arg;
g_debug ("Registering application");
@@ -175,10 +175,9 @@ static gboolean
check_dial_number (const gchar *number)
{
g_autoptr (GError) error = NULL;
GRegex *reject;
g_autoptr (GRegex) reject = g_regex_new (REJECT_RE, 0, 0, &error);
gboolean matches;
reject = g_regex_new (REJECT_RE, 0, 0, &error);
if (!reject)
{
g_warning ("Could not compile regex for"
@@ -198,11 +197,10 @@ check_dial_number (const gchar *number)
static gchar *
extract_dial_string (const gchar *number)
{
g_autoptr(GError) error = NULL;
g_autoptr(GRegex) replace_visual;
g_autoptr (GError) error = NULL;
g_autoptr (GRegex) replace_visual = g_regex_new (VISUAL_RE, 0, 0, &error);
gchar *dial_string;
replace_visual = g_regex_new (VISUAL_RE, 0, 0, &error);
if (!replace_visual)
{
g_warning ("Could not compile regex for"
@@ -298,8 +296,8 @@ static const GActionEntry actions[] =
static void
startup (GApplication *application)
{
g_autoptr(GtkCssProvider) provider = NULL;
g_autoptr(GError) error = NULL;
g_autoptr (GtkCssProvider) provider = NULL;
g_autoptr (GError) error = NULL;
G_APPLICATION_CLASS (calls_application_parent_class)->startup (application);
Loading