Date: Thu, 22 Jun 2017 23:55:02 +0000 (UTC) From: Jan Beich <jbeich@FreeBSD.org> To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r444161 - in head/devel: android-tools-adb-devel/files android-tools-fastboot-devel/files Message-ID: <201706222355.v5MNt2W6098665@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: jbeich Date: Thu Jun 22 23:55:02 2017 New Revision: 444161 URL: https://svnweb.freebsd.org/changeset/ports/444161 Log: devel/android-tools-{adb,fastboot}-devel: adjust KERN_PROC_PATHNAME after r444135 Modified: head/devel/android-tools-adb-devel/files/patch-base_file.cpp (contents, props changed) head/devel/android-tools-fastboot-devel/files/patch-base_file.cpp (contents, props changed) Modified: head/devel/android-tools-adb-devel/files/patch-base_file.cpp ============================================================================== --- head/devel/android-tools-adb-devel/files/patch-base_file.cpp Thu Jun 22 23:43:08 2017 (r444160) +++ head/devel/android-tools-adb-devel/files/patch-base_file.cpp Thu Jun 22 23:55:02 2017 (r444161) @@ -21,7 +21,7 @@ #if defined(_WIN32) #include <windows.h> #define O_CLOEXEC O_NOINHERIT -@@ -251,6 +257,17 @@ std::string GetExecutablePath() { +@@ -251,6 +258,23 @@ std::string GetExecutablePath() { if (result == 0 || result == sizeof(path) - 1) return ""; path[PATH_MAX - 1] = 0; return path; @@ -30,9 +30,15 @@ + size_t path_len = sizeof(path); + int mib[] = { + CTL_KERN, ++#if defined(__NetBSD__) ++ KERN_PROC_ARGS, ++ -1, ++ KERN_PROC_PATHNAME, ++#else + KERN_PROC, + KERN_PROC_PATHNAME, -+ getpid() ++ -1, ++#endif + }; + int rc = sysctl(mib, arraysize(mib), path, &path_len, NULL, 0); + return rc ? "" : path; Modified: head/devel/android-tools-fastboot-devel/files/patch-base_file.cpp ============================================================================== --- head/devel/android-tools-fastboot-devel/files/patch-base_file.cpp Thu Jun 22 23:43:08 2017 (r444160) +++ head/devel/android-tools-fastboot-devel/files/patch-base_file.cpp Thu Jun 22 23:55:02 2017 (r444161) @@ -21,7 +21,7 @@ #if defined(_WIN32) #include <windows.h> #define O_CLOEXEC O_NOINHERIT -@@ -251,6 +257,17 @@ std::string GetExecutablePath() { +@@ -251,6 +258,23 @@ std::string GetExecutablePath() { if (result == 0 || result == sizeof(path) - 1) return ""; path[PATH_MAX - 1] = 0; return path; @@ -30,9 +30,15 @@ + size_t path_len = sizeof(path); + int mib[] = { + CTL_KERN, ++#if defined(__NetBSD__) ++ KERN_PROC_ARGS, ++ -1, ++ KERN_PROC_PATHNAME, ++#else + KERN_PROC, + KERN_PROC_PATHNAME, -+ getpid() ++ -1, ++#endif + }; + int rc = sysctl(mib, arraysize(mib), path, &path_len, NULL, 0); + return rc ? "" : path;
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201706222355.v5MNt2W6098665>