From: Sergey Poznyakoff Date: Wed, 14 Sep 2005 13:23:12 +0000 (+0000) Subject: (list_dumpdir): New function. Used to dump contents of GNUTYPE_DUMPDIR blocks. X-Git-Url: https://git.dogcows.com/gitweb?a=commitdiff_plain;h=9093ca15d8277d2b14efab9f19dd9eeed6e997ca;p=chaz%2Ftar (list_dumpdir): New function. Used to dump contents of GNUTYPE_DUMPDIR blocks. --- diff --git a/src/incremen.c b/src/incremen.c index 9902d10..e5c280a 100644 --- a/src/incremen.c +++ b/src/incremen.c @@ -557,3 +557,32 @@ purge_directory (char const *directory_name) free (current_dir); free (archive_dir); } + +void +list_dumpdir (char *buffer, size_t size) +{ + while (size) + { + switch (*buffer) + { + case 'Y': + case 'N': + case 'D': + fprintf (stdlis, "%c ", *buffer); + buffer++; + size--; + break; + + case 0: + fputc ('\n', stdlis); + buffer++; + size--; + break; + + default: + fputc (*buffer, stdlis); + buffer++; + size--; + } + } +}