Ecere Software
/
sdk
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
cdb5d1c
)
instance.c: Defaulting to /proc/curproc/file when locating module on FreeBSD
author
Jerome St-Louis
<jerome@ecere.com>
Thu, 7 Mar 2013 05:17:34 +0000
(
00:17
-0500)
committer
Jerome St-Louis
<jerome@ecere.com>
Thu, 7 Mar 2013 05:17:34 +0000
(
00:17
-0500)
ecere/src/com/instance.c
patch
|
blob
|
history
diff --git
a/ecere/src/com/instance.c
b/ecere/src/com/instance.c
index
9374e91
..
3389e4d
100644
(file)
--- a/
ecere/src/com/instance.c
+++ b/
ecere/src/com/instance.c
@@
-235,7
+235,12
@@
bool Instance_LocateModule(char * name, char * fileName)
}
if(!name || !name[0])
{
- strcpy(fileName, exeLocation);
+#if !defined(__linux__)
+ if(!access("/proc/curproc/file", F_OK))
+ strcpy(fileName, "/proc/curproc/file");
+ else
+#endif
+ strcpy(fileName, exeLocation);
return true;
}
#endif