[epiphany/wip/ephy-sync] Discard some unnecessary logs
- From: Gabriel - Cristian Ivascu <gabrielivascu src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [epiphany/wip/ephy-sync] Discard some unnecessary logs
- Date: Fri, 22 Jul 2016 16:18:07 +0000 (UTC)
commit e20fbaa0afd6f5a44b3bf0c8f45f0bf302683a3b
Author: Gabriel Ivascu <ivascu gabriel59 gmail com>
Date: Fri Jul 22 19:13:50 2016 +0300
Discard some unnecessary logs
src/ephy-sync-secret.c | 18 ++++--------------
src/ephy-sync-service.c | 9 ---------
2 files changed, 4 insertions(+), 23 deletions(-)
---
diff --git a/src/ephy-sync-secret.c b/src/ephy-sync-secret.c
index e52babc..4fe6829 100644
--- a/src/ephy-sync-secret.c
+++ b/src/ephy-sync-secret.c
@@ -16,7 +16,6 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-#include "ephy-debug.h"
#include "ephy-sync-secret.h"
#include <glib/gi18n.h>
@@ -45,10 +44,8 @@ forget_all_tokens_cb (SecretService *service,
secret_service_clear_finish (service, result, &error);
- if (error)
-LOG ("[%d] Error clearing token secret schema: %s", __LINE__, error->message);
- else
-LOG ("[%d] Successfully cleared token secret schema", __LINE__);
+ if (error != NULL)
+ g_warning ("Failed to clear token secret schema: %s", error->message);
}
static void
@@ -60,10 +57,8 @@ store_token_cb (SecretService *service,
secret_service_store_finish (service, result, &error);
- if (error)
-LOG ("[%d] Error storing token in secret schema: %s", __LINE__, error->message);
- else
-LOG ("[%d] Successfully stored token in secret schema", __LINE__);
+ if (error != NULL)
+ g_warning ("Failed to store token in secret schema: %s", error->message);
}
void
@@ -94,7 +89,6 @@ ephy_sync_secret_load_tokens (EphySyncService *sync_service)
EphySyncServiceTokenType type;
const gchar *emailUTF8;
const gchar *value;
- const gchar *name;
gchar *user_email;
user_email = ephy_sync_service_get_user_email (sync_service);
@@ -115,7 +109,6 @@ ephy_sync_secret_load_tokens (EphySyncService *sync_service)
emailUTF8 = g_hash_table_lookup (attributes, EMAIL_KEY);
type = g_ascii_strtoull (g_hash_table_lookup (attributes, TOKEN_TYPE_KEY),
NULL, 10);
- name = g_hash_table_lookup (attributes, TOKEN_NAME_KEY);
secret_value = secret_item_get_secret (secret_item);
value = secret_value_get_text (secret_value);
@@ -124,7 +117,6 @@ ephy_sync_secret_load_tokens (EphySyncService *sync_service)
continue;
ephy_sync_service_set_token (sync_service, g_strdup (value), type);
-LOG ("[%d] Loaded token %s with value %s for email %s", __LINE__, name, value, emailUTF8);
g_hash_table_unref (attributes);
}
@@ -145,8 +137,6 @@ ephy_sync_secret_store_token (const gchar *emailUTF8,
g_return_if_fail (emailUTF8);
g_return_if_fail (value);
-LOG ("[%d] Storing token %s with value %s for email %s ", __LINE__, ephy_sync_service_token_name_from_type
(type), value, emailUTF8);
-
name = ephy_sync_service_token_name_from_type (type);
secret_value = secret_value_new (value, -1, "text/plain");
attributes = secret_attributes_build (EPHY_SYNC_TOKEN_SCHEMA,
diff --git a/src/ephy-sync-service.c b/src/ephy-sync-service.c
index bfffef2..2feb32b 100644
--- a/src/ephy-sync-service.c
+++ b/src/ephy-sync-service.c
@@ -137,9 +137,7 @@ synchronous_hawk_get_request (EphySyncService *self,
NULL);
soup_message_headers_append (message->request_headers,
"authorization", hawk_header->header);
-LOG ("[%d] Sending synchronous HAWK GET request to %s endpoint", __LINE__, endpoint);
soup_session_send_message (self->soup_session, message);
-LOG ("[%d] Got response from server: %u", __LINE__, message->status_code);
if (node != NULL) {
parser = json_parser_new ();
@@ -472,8 +470,6 @@ ephy_sync_service_init (EphySyncService *self)
ephy_sync_service_set_user_email (self, sync_user);
ephy_sync_secret_load_tokens (self);
}
-
-LOG ("[%d] sync service inited", __LINE__);
}
EphySyncService *
@@ -606,8 +602,6 @@ ephy_sync_service_delete_all_tokens (EphySyncService *self)
g_clear_pointer (&self->unwrapBKey, g_free);
g_clear_pointer (&self->kA, g_free);
g_clear_pointer (&self->kB, g_free);
-
-LOG ("[%d] Deleted all tokens", __LINE__);
}
void
@@ -709,9 +703,6 @@ ephy_sync_service_fetch_sync_keys (EphySyncService *self,
NULL);
retval = TRUE;
-LOG ("kA: %s", ephy_sync_crypto_encode_hex (sync_keys->kA, 0));
-LOG ("kB: %s", ephy_sync_crypto_encode_hex (sync_keys->kB, 0));
-
out:
ephy_sync_crypto_processed_kft_free (processed_kft);
ephy_sync_crypto_sync_keys_free (sync_keys);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]