summaryrefslogtreecommitdiffstats
path: root/printf.h
diff options
context:
space:
mode:
authorTavian Barnes <tavianator@tavianator.com>2019-05-04 11:51:56 -0400
committerTavian Barnes <tavianator@tavianator.com>2019-05-04 11:55:07 -0400
commit09119a3e8fa5f206eb4254144a1c8e77bc6e587e (patch)
tree924146ec43e912f2271ab90a470cd09492919db7 /printf.h
parentd8e10d648b12b8595e9f177ec8f1a71d24aecea5 (diff)
downloadbfs-09119a3e8fa5f206eb4254144a1c8e77bc6e587e.tar.xz
bftw: Add a caching stat() API to struct BFTW
Diffstat (limited to 'printf.h')
-rw-r--r--printf.h16
1 files changed, 4 insertions, 12 deletions
diff --git a/printf.h b/printf.h
index 1c3957e..d62770e 100644
--- a/printf.h
+++ b/printf.h
@@ -1,6 +1,6 @@
/****************************************************************************
* bfs *
- * Copyright (C) 2017-2018 Tavian Barnes <tavianator@tavianator.com> *
+ * Copyright (C) 2017-2019 Tavian Barnes <tavianator@tavianator.com> *
* *
* Permission to use, copy, modify, and/or distribute this software for any *
* purpose with or without fee is hereby granted. *
@@ -22,22 +22,14 @@
#define BFS_PRINTF_H
#include "bftw.h"
-#include "color.h"
+#include "cmdline.h"
#include <stdbool.h>
#include <stdio.h>
-struct cmdline;
-struct bfs_printf_directive;
-
/**
* A printf command, the result of parsing a single format string.
*/
-struct bfs_printf {
- /** The chain of printf directives. */
- struct bfs_printf_directive *directives;
- /** Whether the struct bfs_stat must be filled in. */
- bool needs_stat;
-};
+struct bfs_printf;
/**
* Parse a -printf format string.
@@ -62,7 +54,7 @@ struct bfs_printf *parse_bfs_printf(const char *format, struct cmdline *cmdline)
* must be non-NULL.
* @return 0 on success, -1 on failure.
*/
-int bfs_printf(FILE *file, const struct bfs_printf *command, const struct BFTW *ftwbuf);
+int bfs_printf(FILE *file, const struct bfs_printf *command, struct BFTW *ftwbuf);
/**
* Free a parsed format string.