summaryrefslogtreecommitdiffstats
path: root/adb
diff options
context:
space:
mode:
authorElliott Hughes <enh@google.com>2014-11-20 18:47:24 +0000
committerAndroid Git Automerger <android-git-automerger@android.com>2014-11-20 18:47:24 +0000
commitb99dbe9aaf6ba50ecfdfd3de2affc22eb6dc14ff (patch)
treea04bfb87d3b1660afe873e302e53d4715e6e0ea5 /adb
parent330c3ee9449670cd56954b9e5d107f7b450f76d5 (diff)
parent4c2aec09cf2da437f3995ff4cac87e4c20d1d4b0 (diff)
downloadsystem_core-b99dbe9aaf6ba50ecfdfd3de2affc22eb6dc14ff.zip
system_core-b99dbe9aaf6ba50ecfdfd3de2affc22eb6dc14ff.tar.gz
system_core-b99dbe9aaf6ba50ecfdfd3de2affc22eb6dc14ff.tar.bz2
am 4c2aec09: am aa3e17e1: Merge "Return path including executable instead of without"
* commit '4c2aec09cf2da437f3995ff4cac87e4c20d1d4b0': Return path including executable instead of without
Diffstat (limited to 'adb')
-rw-r--r--adb/get_my_path_darwin.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/adb/get_my_path_darwin.c b/adb/get_my_path_darwin.c
index 9141b57..65dd226 100644
--- a/adb/get_my_path_darwin.c
+++ b/adb/get_my_path_darwin.c
@@ -20,11 +20,11 @@
void get_my_path(char *s, size_t maxLen)
{
CFBundleRef mainBundle = CFBundleGetMainBundle();
- CFURLRef bundleURL = CFBundleCopyBundleURL(mainBundle);
- CFStringRef bundlePathString = CFURLCopyFileSystemPath(bundleURL, kCFURLPOSIXPathStyle);
- CFRelease(bundleURL);
+ CFURLRef executableURL = CFBundleCopyExecutableURL(mainBundle);
+ CFStringRef executablePathString = CFURLCopyFileSystemPath(executableURL, kCFURLPOSIXPathStyle);
+ CFRelease(executableURL);
- CFStringGetCString(bundlePathString, s, maxLen, kCFStringEncodingASCII);
- CFRelease(bundlePathString);
+ CFStringGetCString(executablePathString, s, maxLen, kCFStringEncodingASCII);
+ CFRelease(executablePathString);
}