summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorSebastian Dransfeld <sebastian.dransfeld@sintef.no>2013-08-07 11:51:32 +0200
committerSebastian Dransfeld <sebastian.dransfeld@sintef.no>2013-08-07 13:02:54 +0200
commite011d5e67cef7d953f72f15950655c79331468c6 (patch)
treed2737844468c15f06057d8f3a03f4f8f4d1948f0 /src
parent35a45eb062a871d2562c054922acc67df7237739 (diff)
efreet: be paranoid about '\0' termination
CID: #1039721
Diffstat (limited to 'src')
-rw-r--r--src/lib/efreet/efreet_trash.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/lib/efreet/efreet_trash.c b/src/lib/efreet/efreet_trash.c
index a392cf1397..1301b831b9 100644
--- a/src/lib/efreet/efreet_trash.c
+++ b/src/lib/efreet/efreet_trash.c
@@ -103,6 +103,7 @@ efreet_trash_dir_get(const char *file)
103 while (strlen(buf) > 1) 103 while (strlen(buf) > 1)
104 { 104 {
105 strncpy(path, buf, PATH_MAX); 105 strncpy(path, buf, PATH_MAX);
106 path[PATH_MAX - 1] = 0;
106 dir = dirname(buf); 107 dir = dirname(buf);
107 108
108 if (stat(dir, &s_dest) == 0) 109 if (stat(dir, &s_dest) == 0)