Merge six easy pieces from the BUF_REMOVAL branch:
r14271  Audit a few buffer sizes, increase one.
r14280  Audit buffer size.
r14296  Remove a few unneeded header files.
r14310  Replace fixed size buffers with a large enough buffers.
r14338  Remove a dead assignment in print_bbcs and make global variable
        print_fd a local variable.
r14359  Remove a benign macro redefinition in cachegrind.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@14595 a5019735-40e9-0310-863c-91ae7b9d1cf9
diff --git a/exp-dhat/dh_main.c b/exp-dhat/dh_main.c
index 78465ee..2730385 100644
--- a/exp-dhat/dh_main.c
+++ b/exp-dhat/dh_main.c
@@ -1094,7 +1094,7 @@
 
 static void show_APInfo ( APInfo* api )
 {
-   HChar bufA[80];
+   HChar bufA[80];   // large enough
    VG_(memset)(bufA, 0, sizeof(bufA));
    if (api->tot_blocks > 0) {
       show_N_div_100( bufA, ((ULong)api->tot_bytes * 100ULL)
@@ -1121,7 +1121,7 @@
       ULong aad_frac_10k
          = g_guest_instrs_executed == 0
            ? 0 : (10000ULL * aad) / g_guest_instrs_executed;
-      HChar buf[16];
+      HChar buf[80];  // large enough
       show_N_div_100(buf, aad_frac_10k);
       VG_(umsg)("deaths:      %'llu, at avg age %'llu "
                 "(%s%% of prog lifetime)\n",
@@ -1130,7 +1130,7 @@
       VG_(umsg)("deaths:      none (none of these blocks were freed)\n");
    }
 
-   HChar bufR[80], bufW[80];
+   HChar bufR[80], bufW[80];   // large enough
    VG_(memset)(bufR, 0, sizeof(bufR));
    VG_(memset)(bufW, 0, sizeof(bufW));
    if (api->tot_bytes > 0) {