Blame SOURCES/0008-Remove-function-malloc_readlink.patch

50b851
From f5f7f625ff489bf0e68f4b99503188b7006807ce Mon Sep 17 00:00:00 2001
50b851
From: Matej Habrnal <mhabrnal@redhat.com>
50b851
Date: Fri, 13 Mar 2015 16:11:01 +0100
50b851
Subject: [PATCH] Remove function malloc_readlink
50b851
50b851
The same function was added to the libreport so there was a conflict between
50b851
them.
50b851
50b851
Related to #1185626
50b851
50b851
Signed-off-by: Matej Habrnal <mhabrnal@redhat.com>
50b851
---
50b851
 src/abrt-checker.c | 23 -----------------------
50b851
 1 file changed, 23 deletions(-)
50b851
50b851
diff --git a/src/abrt-checker.c b/src/abrt-checker.c
50b851
index 56f2fa4..4e1a450 100644
50b851
--- a/src/abrt-checker.c
50b851
+++ b/src/abrt-checker.c
50b851
@@ -1039,29 +1039,6 @@ static void get_thread_name(
50b851
 }
50b851
 
50b851
 
50b851
-/*
50b851
- * Read executable name from link /proc/${PID}/exe
50b851
- */
50b851
-static char* malloc_readlink(const char *linkname)
50b851
-{
50b851
-    char buf[PATH_MAX + 1];
50b851
-    int len;
50b851
-
50b851
-    len = readlink(linkname, buf, sizeof(buf)-1);
50b851
-    if (len >= 0)
50b851
-    {
50b851
-        buf[len] = '\0';
50b851
-        char *p = malloc(strlen(buf) + 1);
50b851
-        if (p)
50b851
-        {
50b851
-            strcpy(p, buf);
50b851
-        }
50b851
-        return p;
50b851
-    }
50b851
-    return NULL;
50b851
-}
50b851
-
50b851
-
50b851
 
50b851
 /*
50b851
  * Read executable name from the special file /proc/${PID}/exe
50b851
-- 
50b851
2.4.6
50b851