From da7d6dbe3004292fc06b1ff952593d6ff4a74a91 Mon Sep 17 00:00:00 2001 From: sebastid Date: Mon, 10 Oct 2005 21:10:04 +0000 Subject: [PATCH] dst, not src in second realpath SVN revision: 17409 --- legacy/ecore/src/lib/ecore_file/ecore_file.c | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/legacy/ecore/src/lib/ecore_file/ecore_file.c b/legacy/ecore/src/lib/ecore_file/ecore_file.c index e85ad1dc8a..74154d1284 100644 --- a/legacy/ecore/src/lib/ecore_file/ecore_file.c +++ b/legacy/ecore/src/lib/ecore_file/ecore_file.c @@ -129,12 +129,14 @@ ecore_file_cp(const char *src, const char *dst) char realpath2[PATH_MAX]; size_t num; - if (realpath(src, realpath1) && realpath(src,realpath2)) - if (!strcmp(realpath1, realpath2)) - return 0; - else - return 0; - + if (realpath(src, realpath1) && realpath(dst, realpath2)) + { + if (!strcmp(realpath1, realpath2)) + return 0; + } + else + return 0; + f1 = fopen(src, "rb"); if (!f1) return 0; f2 = fopen(dst, "wb");