summaryrefslogtreecommitdiff
path: root/TSRM/tsrm_virtual_cwd.c
diff options
context:
space:
mode:
authorIlia Alshanetsky <iliaa@php.net>2002-10-22 18:57:59 +0000
committerIlia Alshanetsky <iliaa@php.net>2002-10-22 18:57:59 +0000
commite94b9ea9eefd15ea9e33a2f4b270b2e598f2575d (patch)
treea3b2b3d060ed555ca617a7b3f2f2c761a4628faf /TSRM/tsrm_virtual_cwd.c
parent62aefeb01fc9095a8bcf5efbd83bc4796bc07c6e (diff)
downloadphp-git-e94b9ea9eefd15ea9e33a2f4b270b2e598f2575d.tar.gz
Fixed a bug noticed by Jon Parise.
Diffstat (limited to 'TSRM/tsrm_virtual_cwd.c')
-rw-r--r--TSRM/tsrm_virtual_cwd.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/TSRM/tsrm_virtual_cwd.c b/TSRM/tsrm_virtual_cwd.c
index 4e12b955fb..ce4f2538f2 100644
--- a/TSRM/tsrm_virtual_cwd.c
+++ b/TSRM/tsrm_virtual_cwd.c
@@ -289,9 +289,9 @@ CWD_API char *virtual_link(char *buf, size_t size TSRMLS_DC)
char resolved_path[MAXPATHLEN];
if (IS_ABSOLUTE_PATH(buf, size)) {
- memcpy(resolved_path, buf, size);
- p[size] = '\0';
p = resolved_path;
+ memcpy(p, buf, size);
+ p[size] = '\0';
} else {
virtual_getcwd(tmp_path, MAXPATHLEN TSRMLS_CC);
p = tmp_path + strlen(tmp_path);