Created
August 15, 2017 21:32
-
-
Save qwwdfsad/1b0d8ba61bb0d688d75672d2100aa371 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Index: src/jattach.c | |
IDEA additional info: | |
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP | |
<+>UTF-8 | |
=================================================================== | |
--- src/jattach.c (revision 09e208d593344430de0bb7b4e72273cef93b29ff) | |
+++ src/jattach.c (revision ) | |
@@ -150,6 +150,16 @@ | |
return 1; | |
} | |
+#ifdef __APPLE__ | |
+ char* path = argv[3]; | |
+ char real_path[PATH_MAX]; | |
+ if (!realpath(path, real_path)) { | |
+ perror("Cannot canonicalize path"); | |
+ return 1; | |
+ } | |
+ argv[3] = real_path; | |
+#endif // __APPLE__ | |
+ | |
// Make write() return EPIPE instead of silent process termination | |
signal(SIGPIPE, SIG_IGN); | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment