[devhelp/wip/misc] DhLink: small code refactorings



commit b05c71a2d9ffea6efcfc89ffb8d2f9ee11e1af7a
Author: Sébastien Wilmet <swilmet gnome org>
Date:   Sat Jun 3 17:57:12 2017 +0200

    DhLink: small code refactorings
    
    - in link_free(), free the string fields in the same order as declared
    in the struct.

 src/dh-link.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/src/dh-link.c b/src/dh-link.c
index bf828e9..acb7f09 100644
--- a/src/dh-link.c
+++ b/src/dh-link.c
@@ -61,11 +61,11 @@ G_DEFINE_BOXED_TYPE (DhLink, dh_link,
 static void
 link_free (DhLink *link)
 {
-        g_free (link->base_path);
         g_free (link->book_id);
+        g_free (link->base_path);
         g_free (link->name);
-        g_free (link->relative_url);
         g_free (link->name_collation_key);
+        g_free (link->relative_url);
 
         if (link->book != NULL)
                 dh_link_unref (link->book);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]