fix +CMGR result parsing error
[platform/core/telephony/tel-plugin-imc.git] / src / s_common.c
index 7af8819..430aa2f 100644 (file)
@@ -116,7 +116,7 @@ char* util_hexStringToBytes(char *s)
 
        for (i = 0; i < sz; i += 2) {
                ret[i / 2] = (char) ((util_hexCharToInt(s[i]) << 4) | util_hexCharToInt(s[i + 1]));
-               dbg("[%02x]", ret[i / 2]);
+               msg("           [%02x]", ret[i / 2]);
        }
 
        return ret;
@@ -186,7 +186,7 @@ char* util_removeQuotes(void *data)
                return NULL;
        }
 
-       tmp = g_try_malloc(data_len - 1);
+       tmp = g_try_malloc0(data_len - 1);
        memcpy(tmp, data + 1, data_len - 2);
        dbg("tmp: [%s]", tmp);