[gnome-settings-daemon/gnome-3-12] EDID strings can be up to 13 bytes



commit c32362174345c8018c178dbbecda29ec464257ed
Author: Florian Höch <florian hoech gmx de>
Date:   Fri Mar 28 14:10:57 2014 +0100

    EDID strings can be up to 13 bytes
    
    The EDID specification allows up to 13 bytes for text blocks.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=727240

 plugins/color/gcm-edid.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/plugins/color/gcm-edid.c b/plugins/color/gcm-edid.c
index 2599d6c..e73f438 100644
--- a/plugins/color/gcm-edid.c
+++ b/plugins/color/gcm-edid.c
@@ -240,9 +240,9 @@ gcm_edid_parse_string (const guint8 *data)
         guint i;
         guint replaced = 0;
 
-        /* this is always 12 bytes, but we can't guarantee it's null
+        /* this is always 13 bytes, but we can't guarantee it's null
          * terminated or not junk. */
-        text = g_strndup ((const gchar *) data, 12);
+        text = g_strndup ((const gchar *) data, 13);
 
         /* remove insane newline chars */
         g_strdelimit (text, "\n\r", '\0');


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