1 $NetBSD: patch-ab,v 1.9 2012/08/24 12:48:11 ryoon Exp $
3 --- zfuncs.cc.orig 2012-08-04 11:58:30.000000000 +0000
5 @@ -81,6 +81,7 @@ void zappcrash(cchar *pMess, ... )
7 printf("*** zappcrash: \n %s \n",message); // output message to stdout
9 +#if defined (HAVE_EXECINFO_H)
10 nstack = backtrace(stacklist,nstack); // get traceback data
11 stackents = backtrace_symbols(stacklist,nstack);
13 @@ -90,6 +91,7 @@ void zappcrash(cchar *pMess, ... )
14 fid1 = fopen("zappcrash","w"); // text file for backtrace
16 fprintf(fid1,"zappcrash: \n %s \n",message); // output message to text file
19 cc = readlink("/proc/self/exe",progexe,300); // get own program path
21 @@ -98,6 +100,7 @@ void zappcrash(cchar *pMess, ... )
25 +#if defined (HAVE_EXECINFO_H)
26 for (ii = 0; ii < nstack; ii++) // output backtrace to text file
29 @@ -117,6 +120,7 @@ void zappcrash(cchar *pMess, ... )
31 fprintf(fid1," %s %s \n",stackents[ii],pfunc); // write to text file