~mdw
/
sgt
/
agedu
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Change the magic number used to introduce a trie file, so that instead
[sgt/agedu]
/
du.h
diff --git
a/du.h
b/du.h
index
9375836
..
f3e36ea
100644
(file)
--- a/
du.h
+++ b/
du.h
@@
-15,10
+15,17
@@
*/
typedef int (*gotdata_fn_t)(void *ctx,
const char *pathname,
*/
typedef int (*gotdata_fn_t)(void *ctx,
const char *pathname,
- const struct stat64 *st);
+ const STRUCT_STAT *st);
+
+/*
+ * Function called to report an error during scanning. The ctx is
+ * the same one passed to gotdata_fn_t.
+ */
+typedef void (*err_fn_t)(void *vctx, const char *fmt, ...);
/*
* Recursively scan a directory tree and report every
* space-consuming item in it to gotdata().
*/
/*
* Recursively scan a directory tree and report every
* space-consuming item in it to gotdata().
*/
-void du(char *path, gotdata_fn_t gotdata, void *gotdata_ctx);
+void du(const char *path, gotdata_fn_t gotdata, err_fn_t err,
+ void *gotdata_ctx);