Logo Search packages:      
Sourcecode: leaktracer version File versions  Download package

void LeakTracer::hexdump ( const unsigned char *  area,
int  size 
)

write a hexdump of the given area.

Definition at line 362 of file LeakTracer.cc.

                                                            {
      fprintf(report, "# ");
      for (int j=0; j < size ; ++j) {
            fprintf (report, "%02x ", *(area+j));
            if (j % 16 == 15) {
                  fprintf(report, "  ");
                  for (int k=-15; k < 0 ; k++) {
                        char c = (char) *(area + j + k);
                        fprintf (report, "%c", isprint(c) ? c : '.');
                  }
                  fprintf(report, "\n# ");
            }
      }
      fprintf(report, "\n");
}

Generated by  Doxygen 1.6.0   Back to index