cpw.nader.asynclogging-3: 2d986a4f: Caught the last few uses of //

morshed.nader at gmail.com morshed.nader at gmail.com
Thu May 12 03:41:36 EDT 2011


----------------------------------------------------------------------
Revision: 2d986a4ffbc6b4c4c33e865bc75dff903479e48b
Parent:   6263ac6e3e58599314613a343aa1fef0f0ed8396
Author:   morshed.nader at gmail.com
Date:     05/12/11 02:46:05
Branch:   im.pidgin.cpw.nader.asynclogging-3
URL: http://d.pidgin.im/viewmtn/revision/info/2d986a4ffbc6b4c4c33e865bc75dff903479e48b

Changelog: 

Caught the last few uses of //

Changes against parent 6263ac6e3e58599314613a343aa1fef0f0ed8396

  patched  libpurple/log.c

-------------- next part --------------
============================================================
--- libpurple/log.c	72e3ee44aa596f2228d13ef72ed05beb19b206d9
+++ libpurple/log.c	48da8b5505668d4ea023241288e22c3fa91fe9d1
@@ -40,7 +40,7 @@
 
 
 #if ! GLIB_CHECK_VERSION(2, 19, 8)
-//Fixes strict-aliasing warning
+/* Fixes strict-aliasing warning */
 #undef g_static_mutex_get_mutex_impl_shortcut
 
 #define g_static_mutex_get_mutex_impl_shortcut(mutex) \
@@ -1611,7 +1611,7 @@ purple_logs_get_total_size(PurpleLogChat
 
 	lu = g_new(_purple_logsize_user, 1);
 	lu->name = g_strdup(purple_normalize(account, name));
-	lu->account = account; //g_object_ref?
+	lu->account = account; /* XXX: g_object_ref? */
 
 	G_LOCK(logsize_users);
 	result = g_hash_table_lookup_extended(logsize_users, lu, NULL, &ptrsize);
@@ -1648,17 +1648,20 @@ purple_logs_get_total_size(PurpleLogChat
 	return total;
 }
 
-// TODO: Would it make sense to allow the caller to pass in a list of logs, if
-// TODO: it just got them from purple_logs_get_logs_async()?  Pidgin asks
-// TODO: for the total size, which means that for some loggers, we end up
-// TODO: calling list *again* needlessly (to loop over them and size them).
-// TODO: If we had a list of logs, we could loop over them and find those
-// TODO: where the logger had a size function (but no total_size function).
-// TODO: We could size just those with something like this (this ignores
-// TODO: the blocking vs. non-blocking distinction for simplicity):
-// TODO: for (...) {
-// TODO: 	if (!log->logger->total_size && log->logger->size)
-// TODO: 		Call the size function.
+/**
+ * XXX: Would it make sense to allow the caller to pass in a list of logs, if
+ * it just got them from purple_logs_get_logs_async()?  Pidgin asks
+ * for the total size, which means that for some loggers, we end up
+ * calling list *again* needlessly (to loop over them and size them).
+ * If we had a list of logs, we could loop over them and find those
+ * where the logger had a size function (but no total_size function).
+ * We could size just those with something like this (this ignores
+ * the blocking vs. non-blocking distinction for simplicity):
+ * for (...) {
+ * 	if (!log->logger->total_size && log->logger->size)
+ * 		Call the size function.
+ * }
+ */
 void
 purple_logs_get_total_size_async(PurpleLogChatType chat_type, const gchar *name,
 	PurpleAccount *account, gint io_priority, GCancellable *cancellable,


More information about the Commits mailing list