Skip to content

Commit

Permalink
*.[ch]: manually align parameter lists
Browse files Browse the repository at this point in the history
In previous patches, extern was mechanically removed from function
declarations without care to formatting, causing parameter lists to be
misaligned. Manually format changed sections such that the parameter
lists should be realigned.

Viewing this patch with 'git diff -w' should produce no output.

Signed-off-by: Denton Liu <[email protected]>
Signed-off-by: Junio C Hamano <[email protected]>
  • Loading branch information
Denton-L authored and gitster committed May 5, 2019
1 parent b199d71 commit ad6dad0
Show file tree
Hide file tree
Showing 44 changed files with 202 additions and 202 deletions.
10 changes: 5 additions & 5 deletions archive.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ struct archiver_args {
/* main api */

int write_archive(int argc, const char **argv, const char *prefix,
struct repository *repo,
const char *name_hint, int remote);
struct repository *repo,
const char *name_hint, int remote);

const char *archive_format_from_filename(const char *filename);

Expand All @@ -52,8 +52,8 @@ typedef int (*write_archive_entry_fn_t)(struct archiver_args *args,

int write_archive_entries(struct archiver_args *args, write_archive_entry_fn_t write_entry);
void *object_file_to_archive(const struct archiver_args *args,
const char *path, const struct object_id *oid,
unsigned int mode, enum object_type *type,
unsigned long *sizep);
const char *path, const struct object_id *oid,
unsigned int mode, enum object_type *type,
unsigned long *sizep);

#endif /* ARCHIVE_H */
14 changes: 7 additions & 7 deletions bisect.h
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@ struct repository;
* best commit, as chosen by `find_all`.
*/
void find_bisection(struct commit_list **list, int *reaches, int *all,
int find_all);
int find_all);

struct commit_list *filter_skipped(struct commit_list *list,
struct commit_list **tried,
int show_all,
int *count,
int *skipped_first);
struct commit_list **tried,
int show_all,
int *count,
int *skipped_first);

#define BISECT_SHOW_ALL (1<<0)
#define REV_LIST_QUIET (1<<1)
Expand All @@ -32,8 +32,8 @@ struct rev_list_info {
};

int bisect_next_all(struct repository *r,
const char *prefix,
int no_checkout);
const char *prefix,
int no_checkout);

int estimate_bisect_steps(int all);

Expand Down
2 changes: 1 addition & 1 deletion branch.h
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,6 @@ void die_if_checked_out(const char *branch, int ignore_current_worktree);
* otherwise.
*/
int replace_each_worktree_head_symref(const char *oldref, const char *newref,
const char *logmsg);
const char *logmsg);

#endif
2 changes: 1 addition & 1 deletion builtin.h
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ struct fmt_merge_msg_opts {
};

int fmt_merge_msg(struct strbuf *in, struct strbuf *out,
struct fmt_merge_msg_opts *);
struct fmt_merge_msg_opts *);

/**
* If a built-in has DELAY_PAGER_CONFIG set, the built-in should call this early
Expand Down
4 changes: 2 additions & 2 deletions bulk-checkin.h
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@
#include "cache.h"

int index_bulk_checkin(struct object_id *oid,
int fd, size_t size, enum object_type type,
const char *path, unsigned flags);
int fd, size_t size, enum object_type type,
const char *path, unsigned flags);

void plug_bulk_checkin(void);
void unplug_bulk_checkin(void);
Expand Down
42 changes: 21 additions & 21 deletions cache.h
Original file line number Diff line number Diff line change
Expand Up @@ -616,7 +616,7 @@ void setup_work_tree(void);
* either 0 upon success and non-zero if no repository was found.
*/
int discover_git_directory(struct strbuf *commondir,
struct strbuf *gitdir);
struct strbuf *gitdir);
const char *setup_git_directory_gently(int *);
const char *setup_git_directory(void);
char *prefix_path(const char *prefix, int len, const char *path);
Expand All @@ -636,16 +636,16 @@ char *prefix_filename(const char *prefix, const char *path);

int check_filename(const char *prefix, const char *name);
void verify_filename(const char *prefix,
const char *name,
int diagnose_misspelt_rev);
const char *name,
int diagnose_misspelt_rev);
void verify_non_filename(const char *prefix, const char *name);
int path_inside_repo(const char *prefix, const char *path);

#define INIT_DB_QUIET 0x0001
#define INIT_DB_EXIST_OK 0x0002

int init_db(const char *git_dir, const char *real_git_dir,
const char *template_dir, unsigned int flags);
const char *template_dir, unsigned int flags);

void sanitize_stdfds(void);
int daemonize(void);
Expand Down Expand Up @@ -673,12 +673,12 @@ int daemonize(void);
/* Initialize and use the cache information */
struct lock_file;
void preload_index(struct index_state *index,
const struct pathspec *pathspec,
unsigned int refresh_flags);
const struct pathspec *pathspec,
unsigned int refresh_flags);
int do_read_index(struct index_state *istate, const char *path,
int must_exist); /* for testting only! */
int must_exist); /* for testting only! */
int read_index_from(struct index_state *, const char *path,
const char *gitdir);
const char *gitdir);
int is_index_unborn(struct index_state *);

/* For use with `write_locked_index()`. */
Expand Down Expand Up @@ -718,8 +718,8 @@ int unmerged_index(const struct index_state *);
* to it.
*/
int repo_index_has_changes(struct repository *repo,
struct tree *tree,
struct strbuf *sb);
struct tree *tree,
struct strbuf *sb);

int verify_path(const char *path, unsigned mode);
int strcmp_offset(const char *s1, const char *s2, size_t *first_change);
Expand Down Expand Up @@ -797,7 +797,7 @@ void *read_blob_data_from_index(const struct index_state *, const char *, unsign
/* don't refresh_fsmonitor state or do stat comparison even if CE_FSMONITOR_VALID is true */
#define CE_MATCH_IGNORE_FSMONITOR 0X20
int is_racy_timestamp(const struct index_state *istate,
const struct cache_entry *ce);
const struct cache_entry *ce);
int ie_match_stat(struct index_state *, const struct cache_entry *, struct stat *, unsigned int);
int ie_modified(struct index_state *, const struct cache_entry *, struct stat *, unsigned int);

Expand All @@ -821,7 +821,7 @@ void fill_stat_data(struct stat_data *sd, struct stat *st);
*/
int match_stat_data(const struct stat_data *sd, struct stat *st);
int match_stat_data_racy(const struct index_state *istate,
const struct stat_data *sd, struct stat *st);
const struct stat_data *sd, struct stat *st);

void fill_stat_cache_info(struct cache_entry *ce, struct stat *st);

Expand Down Expand Up @@ -1386,8 +1386,8 @@ int get_oid_treeish(const char *str, struct object_id *oid);
int get_oid_blob(const char *str, struct object_id *oid);
void maybe_die_on_misspelt_object_name(const char *name, const char *prefix);
enum get_oid_result get_oid_with_context(struct repository *repo, const char *str,
unsigned flags, struct object_id *oid,
struct object_context *oc);
unsigned flags, struct object_id *oid,
struct object_context *oc);

typedef int each_abbrev_fn(const struct object_id *oid, void *);
int for_each_abbrev(const char *prefix, each_abbrev_fn, void *);
Expand Down Expand Up @@ -1469,7 +1469,7 @@ int parse_oid_hex(const char *hex, struct object_id *oid, const char **end);
#define INTERPRET_BRANCH_REMOTE (1<<1)
#define INTERPRET_BRANCH_HEAD (1<<2)
int interpret_branch_name(const char *str, int len, struct strbuf *,
unsigned allowed);
unsigned allowed);
int get_oid_mb(const char *str, struct object_id *oid);

int validate_headref(const char *ref);
Expand All @@ -1480,12 +1480,12 @@ int name_compare(const char *name1, size_t len1, const char *name2, size_t len2)
int cache_name_stage_compare(const char *name1, int len1, int stage1, const char *name2, int len2, int stage2);

void *read_object_with_reference(const struct object_id *oid,
const char *required_type,
unsigned long *size,
struct object_id *oid_ret);
const char *required_type,
unsigned long *size,
struct object_id *oid_ret);

struct object *peel_to_type(const char *name, int namelen,
struct object *o, enum object_type);
struct object *o, enum object_type);

enum date_mode_type {
DATE_NORMAL = 0,
Expand Down Expand Up @@ -1542,8 +1542,8 @@ enum want_ident {
const char *git_author_info(int);
const char *git_committer_info(int);
const char *fmt_ident(const char *name, const char *email,
enum want_ident whose_ident,
const char *date_str, int);
enum want_ident whose_ident,
const char *date_str, int);
const char *fmt_name(enum want_ident);
const char *ident_default_name(void);
const char *ident_default_email(void);
Expand Down
4 changes: 2 additions & 2 deletions checkout.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
* exists, NULL otherwise.
*/
const char *unique_tracking_name(const char *name,
struct object_id *oid,
int *dwim_remotes_matched);
struct object_id *oid,
int *dwim_remotes_matched);

#endif /* CHECKOUT_H */
4 changes: 2 additions & 2 deletions column.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ struct column_options {
struct option;
int parseopt_column_callback(const struct option *, const char *, int);
int git_column_config(const char *var, const char *value,
const char *command, unsigned int *colopts);
const char *command, unsigned int *colopts);
int finalize_colopts(unsigned int *colopts, int stdout_is_tty);
static inline int column_active(unsigned int colopts)
{
Expand All @@ -38,7 +38,7 @@ static inline int column_active(unsigned int colopts)

struct string_list;
void print_columns(const struct string_list *list, unsigned int colopts,
const struct column_options *opts);
const struct column_options *opts);

int run_column_filter(int colopts, const struct column_options *);
int stop_column_filter(void);
Expand Down
44 changes: 22 additions & 22 deletions commit.h
Original file line number Diff line number Diff line change
Expand Up @@ -179,8 +179,8 @@ struct rev_info; /* in revision.h, it circularly uses enum cmit_fmt */

int has_non_ascii(const char *text);
const char *logmsg_reencode(const struct commit *commit,
char **commit_encoding,
const char *output_encoding);
char **commit_encoding,
const char *output_encoding);
const char *repo_logmsg_reencode(struct repository *r,
const struct commit *commit,
char **commit_encoding,
Expand Down Expand Up @@ -245,15 +245,15 @@ int unregister_shallow(const struct object_id *oid);
int for_each_commit_graft(each_commit_graft_fn, void *);
int is_repository_shallow(struct repository *r);
struct commit_list *get_shallow_commits(struct object_array *heads,
int depth, int shallow_flag, int not_shallow_flag);
int depth, int shallow_flag, int not_shallow_flag);
struct commit_list *get_shallow_commits_by_rev_list(
int ac, const char **av, int shallow_flag, int not_shallow_flag);
void set_alternate_shallow_file(struct repository *r, const char *path, int override);
int write_shallow_commits(struct strbuf *out, int use_pack_protocol,
const struct oid_array *extra);
const struct oid_array *extra);
void setup_alternate_shallow(struct lock_file *shallow_lock,
const char **alternate_shallow_file,
const struct oid_array *extra);
const char **alternate_shallow_file,
const struct oid_array *extra);
const char *setup_temporary_shallow(const struct oid_array *extra);
void advertise_shallow_grafts(int);

Expand All @@ -276,8 +276,8 @@ void prepare_shallow_info(struct shallow_info *, struct oid_array *);
void clear_shallow_info(struct shallow_info *);
void remove_nonexistent_theirs_shallow(struct shallow_info *);
void assign_shallow_commits_to_refs(struct shallow_info *info,
uint32_t **used,
int *ref_status);
uint32_t **used,
int *ref_status);
int delayed_reachability_test(struct shallow_info *si, int c);
#define PRUNE_SHOW_ONLY 1
#define PRUNE_QUICK 2
Expand All @@ -286,7 +286,7 @@ extern struct trace_key trace_shallow;

int interactive_add(int argc, const char **argv, const char *prefix, int patch);
int run_add_interactive(const char *revision, const char *patch_mode,
const struct pathspec *pathspec);
const struct pathspec *pathspec);

struct commit_extra_header {
struct commit_extra_header *next;
Expand All @@ -296,19 +296,19 @@ struct commit_extra_header {
};

void append_merge_tag_headers(struct commit_list *parents,
struct commit_extra_header ***tail);
struct commit_extra_header ***tail);

int commit_tree(const char *msg, size_t msg_len,
const struct object_id *tree,
struct commit_list *parents, struct object_id *ret,
const char *author, const char *sign_commit);
const struct object_id *tree,
struct commit_list *parents, struct object_id *ret,
const char *author, const char *sign_commit);

int commit_tree_extended(const char *msg, size_t msg_len,
const struct object_id *tree,
struct commit_list *parents,
struct object_id *ret, const char *author,
const char *sign_commit,
struct commit_extra_header *);
const struct object_id *tree,
struct commit_list *parents,
struct object_id *ret, const char *author,
const char *sign_commit,
struct commit_extra_header *);

struct commit_extra_header *read_commit_extra_headers(struct commit *, const char **);

Expand All @@ -323,13 +323,13 @@ void free_commit_extra_headers(struct commit_extra_header *extra);
* responsibility to parse further in this case!
*/
const char *find_commit_header(const char *msg, const char *key,
size_t *out_len);
size_t *out_len);

/* Find the end of the log message, the right place for a new trailer. */
size_t ignore_non_trailer(const char *buf, size_t len);

typedef int (*each_mergetag_fn)(struct commit *commit, struct commit_extra_header *extra,
void *cb_data);
void *cb_data);

int for_each_mergetag(each_mergetag_fn fn, struct commit *commit, void *data);

Expand All @@ -339,7 +339,7 @@ struct merge_remote_desc {
};
struct merge_remote_desc *merge_remote_util(struct commit *);
void set_merge_remote_desc(struct commit *commit,
const char *name, struct object *obj);
const char *name, struct object *obj);

/*
* Given "name" from the command line to merge, find the commit object
Expand All @@ -349,7 +349,7 @@ void set_merge_remote_desc(struct commit *commit,
struct commit *get_merge_parent(const char *name);

int parse_signed_commit(const struct commit *commit,
struct strbuf *message, struct strbuf *signature);
struct strbuf *message, struct strbuf *signature);
int remove_signature(struct strbuf *buf);

/*
Expand Down
Loading

0 comments on commit ad6dad0

Please sign in to comment.