Andrew's git
/
gitweb.git
/ diff
summary
|
log
|
commit
| diff |
tree
commit
grep
author
committer
pickaxe
?
re
cat-file: move batch_options definition to top of file
author
Jeff King
<peff@peff.net>
Mon, 22 Jun 2015 10:41:03 +0000
(06:41 -0400)
committer
Junio C Hamano
<gitster@pobox.com>
Mon, 22 Jun 2015 21:55:52 +0000
(14:55 -0700)
That way all of the functions can make use of it.
Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/cat-file.c
patch
|
blob
|
history
raw
|
patch
|
inline
| side by side (parent:
ad42f28
)
diff --git
a/builtin/cat-file.c
b/builtin/cat-file.c
index 6cbccccb416238cc5a6839d7af57149a84408e20..d4101b7adaba612d659f5e90d22db98be7563b24 100644
(file)
--- a/
builtin/cat-file.c
+++ b/
builtin/cat-file.c
@@
-10,6
+10,13
@@
#include "streaming.h"
#include "tree-walk.h"
#include "streaming.h"
#include "tree-walk.h"
+struct batch_options {
+ int enabled;
+ int follow_symlinks;
+ int print_contents;
+ const char *format;
+};
+
static int cat_one_file(int opt, const char *exp_type, const char *obj_name,
int unknown_type)
{
static int cat_one_file(int opt, const char *exp_type, const char *obj_name,
int unknown_type)
{
@@
-232,12
+239,6
@@
static void print_object_or_die(int fd, struct expand_data *data)
}
}
}
}
-struct batch_options {
- int enabled;
- int follow_symlinks;
- int print_contents;
- const char *format;
-};
static int batch_one_object(const char *obj_name, struct batch_options *opt,
struct expand_data *data)
static int batch_one_object(const char *obj_name, struct batch_options *opt,
struct expand_data *data)