[gnome-online-accounts/wip/rishi/libsecret-workaround: 4/10] imap-auth-login: Style fixes
- From: Debarshi Ray <debarshir src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-online-accounts/wip/rishi/libsecret-workaround: 4/10] imap-auth-login: Style fixes
- Date: Tue, 4 Jul 2017 17:53:23 +0000 (UTC)
commit c55871c5c836421de50e47b25519d2d0206241a1
Author: Debarshi Ray <debarshir gnome org>
Date: Tue Jul 4 19:47:12 2017 +0200
imap-auth-login: Style fixes
Don't use a separate line to initialize variables.
src/goabackend/goaimapauthlogin.c | 33 ++++++++++-----------------------
1 files changed, 10 insertions(+), 23 deletions(-)
---
diff --git a/src/goabackend/goaimapauthlogin.c b/src/goabackend/goaimapauthlogin.c
index ca992ee..083d653 100644
--- a/src/goabackend/goaimapauthlogin.c
+++ b/src/goabackend/goaimapauthlogin.c
@@ -100,10 +100,9 @@ imap_auth_login_check_BYE (const gchar *response, GError **error)
static gboolean
imap_auth_login_check_NO (const gchar *response, GError **error)
{
- gboolean ret;
- gchar *str;
+ gboolean ret = FALSE;
+ gchar *str = NULL;
- ret = FALSE;
str = g_strdup_printf ("%s NO", IMAP_TAG);
if (g_str_has_prefix (response, str))
@@ -146,9 +145,7 @@ imap_auth_login_check_not_LOGIN (const gchar *response, GError **error)
static gboolean
imap_auth_login_check_not_OK (const gchar *response, gboolean tagged, GError **error)
{
- gboolean ret;
-
- ret = FALSE;
+ gboolean ret = FALSE;
if (tagged)
{
@@ -446,15 +443,10 @@ goa_imap_auth_login_run_sync (GoaMailAuth *auth,
GoaImapAuthLogin *self = GOA_IMAP_AUTH_LOGIN (auth);
GDataInputStream *input;
GDataOutputStream *output;
- gchar *request;
- gchar *response;
- gboolean ret;
- gchar *password;
-
- request = NULL;
- response = NULL;
- password = NULL;
- ret = FALSE;
+ gchar *request = NULL;
+ gchar *response = NULL;
+ gboolean ret = FALSE;
+ gchar *password = NULL;
if (self->password != NULL)
{
@@ -589,14 +581,9 @@ goa_imap_auth_login_starttls_sync (GoaMailAuth *auth,
GoaImapAuthLogin *self = GOA_IMAP_AUTH_LOGIN (auth);
GDataInputStream *input;
GDataOutputStream *output;
- gchar *request;
- gchar *response;
- gboolean ret;
-
- request = NULL;
- response = NULL;
-
- ret = FALSE;
+ gchar *request = NULL;
+ gchar *response = NULL;
+ gboolean ret = FALSE;
input = goa_mail_auth_get_input (auth);
output = goa_mail_auth_get_output (auth);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]