Revise the prevent issue (from private repository)
authorSung-jae Park <nicesj.park@samsung.com>
Thu, 24 Jan 2013 05:33:29 +0000 (05:33 +0000)
committerSung-jae Park <nicesj.park@samsung.com>
Thu, 24 Jan 2013 05:33:29 +0000 (05:33 +0000)
Change-Id: I66d01e56a0247cfa28820e06c3e4fd3c38ebf746

packaging/org.tizen.data-provider-master.spec
src/io.c
src/util.c

index 38bb770..e928c79 100644 (file)
@@ -1,6 +1,6 @@
 Name: org.tizen.data-provider-master
 Summary: Master data provider
-Version: 0.14.3
+Version: 0.14.4
 Release: 1
 Group: main/app
 License: Flora License
index 7062420..f078832 100644 (file)
--- a/src/io.c
+++ b/src/io.c
@@ -69,8 +69,8 @@ static inline int load_abi_table(void)
        };
        const char *ptr;
 
-       char group[MAX_ABI];
-       char pkgname[MAX_PKGNAME];
+       char group[MAX_ABI + 1];
+       char pkgname[MAX_PKGNAME + 1];
 
        fp = fopen("/usr/share/"PACKAGE"/abi.ini", "rt");
        if (!fp)
index 13c5ca9..690df7e 100644 (file)
@@ -232,7 +232,7 @@ HAPI char *util_replace_string(const char *src, const char *pattern, const char
        int matched;
 
        bufsz = strlen(src);
-       incsz = bufsz;
+       incsz = bufsz + 1; /* Including the NULL byte */
        ret = malloc(bufsz + 1);
        if (!ret) {
                ErrPrint("Heap: %s\n", strerror(errno));