summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/crash.cc
diff options
context:
space:
mode:
authorSamuel Bronson <naesten@gmail.com>2013-11-02 23:33:06 -0400
committerSamuel Bronson <naesten@gmail.com>2013-11-02 23:33:06 -0400
commit330552f8ea10e1ac6a8383d4a135f2040f94629d (patch)
tree3300c45f38184c638fadc658ad80d455d63a233c /crawl-ref/source/crash.cc
parent315f20b8f696447a572f717c560ec7af1a1e7960 (diff)
downloadcrawl-ref-330552f8ea10e1ac6a8383d4a135f2040f94629d.tar.gz
crawl-ref-330552f8ea10e1ac6a8383d4a135f2040f94629d.zip
Clear some buffers prominent in crash traces
This lets GDB avoid having to print out all that extraneous garbage.
Diffstat (limited to 'crawl-ref/source/crash.cc')
-rw-r--r--crawl-ref/source/crash.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/crawl-ref/source/crash.cc b/crawl-ref/source/crash.cc
index fee144a08c..4868a41372 100644
--- a/crawl-ref/source/crash.cc
+++ b/crawl-ref/source/crash.cc
@@ -371,7 +371,7 @@ void call_gdb(FILE *file)
fprintf(file, "Trying to run gdb.\n");
fflush(file); // so we can use fileno()
- char pid[12];
+ char pid[12] = {};
snprintf(pid, sizeof(pid), "%d", getpid());
switch (int gdb = fork())