https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61895
--- Comment #3 from ian at gcc dot gnu.org <ian at gcc dot gnu.org> --- Author: ian Date: Sat Aug 2 00:53:58 2014 New Revision: 213512 URL: https://gcc.gnu.org/viewcvs?rev=213512&root=gcc&view=rev Log: PR other/61895 runtime: Ignore small argv[0] file for backtrace. Reportedly in some cases Docker starts processes with argv[0] pointing to an empty file. That would cause libgo to pass that empty file to libbacktrace, which would then fail to do any backtraces. Everything should work fine if libbacktrace falls back to /proc/self/exe. This patch to libgo works around the problem by ignoring argv[0] if it is a small file, or if stat fails. This is not a perfect fix but it's an unusual problem. Modified: branches/gcc-4_9-branch/libgo/runtime/go-caller.c