Commit 379c46463cbdd73e04c5efc180309d4600e56624

punkymaniac 2021-09-09T19:49:04

Fix coding style for pointer Make some syntax change to follow coding style.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
diff --git a/include/git2/clone.h b/include/git2/clone.h
index 2d6f687..3c3ea26 100644
--- a/include/git2/clone.h
+++ b/include/git2/clone.h
@@ -133,7 +133,7 @@ typedef struct git_clone_options {
 	 * The name of the branch to checkout. NULL means use the
 	 * remote's default branch.
 	 */
-	const char* checkout_branch;
+	const char *checkout_branch;
 
 	/**
 	 * A callback used to create the new repository into which to
diff --git a/include/git2/notes.h b/include/git2/notes.h
index c36149e..c135881 100644
--- a/include/git2/notes.h
+++ b/include/git2/notes.h
@@ -84,8 +84,8 @@ GIT_EXTERN(void) git_note_iterator_free(git_note_iterator *it);
  *         (negative value)
  */
 GIT_EXTERN(int) git_note_next(
-	git_oid* note_id,
-	git_oid* annotated_id,
+	git_oid *note_id,
+	git_oid *annotated_id,
 	git_note_iterator *it);
 
 
diff --git a/include/git2/remote.h b/include/git2/remote.h
index 51a7d1c..4d57eaa 100644
--- a/include/git2/remote.h
+++ b/include/git2/remote.h
@@ -243,7 +243,7 @@ GIT_EXTERN(const char *) git_remote_pushurl(const git_remote *remote);
  * @param url the url to set
  * @return 0 or an error value
  */
-GIT_EXTERN(int) git_remote_set_url(git_repository *repo, const char *remote, const char* url);
+GIT_EXTERN(int) git_remote_set_url(git_repository *repo, const char *remote, const char *url);
 
 /**
  * Set the remote's url for pushing in the configuration.
@@ -257,7 +257,7 @@ GIT_EXTERN(int) git_remote_set_url(git_repository *repo, const char *remote, con
  * @param url the url to set
  * @return 0, or an error code
  */
-GIT_EXTERN(int) git_remote_set_pushurl(git_repository *repo, const char *remote, const char* url);
+GIT_EXTERN(int) git_remote_set_pushurl(git_repository *repo, const char *remote, const char *url);
 
 /**
  * Set the url for this particular url instance.  The URL in the
@@ -451,7 +451,7 @@ typedef int GIT_CALLBACK(git_push_transfer_progress_cb)(
 	unsigned int current,
 	unsigned int total,
 	size_t bytes,
-	void* payload);
+	void *payload);
 
 /**
  * Represents an update which will be performed on the remote during push
diff --git a/include/git2/repository.h b/include/git2/repository.h
index 45becc7..e699016 100644
--- a/include/git2/repository.h
+++ b/include/git2/repository.h
@@ -797,8 +797,8 @@ GIT_EXTERN(int) git_repository_hashfile(
  * @return 0 on success, or an error code
  */
 GIT_EXTERN(int) git_repository_set_head(
-	git_repository* repo,
-	const char* refname);
+	git_repository *repo,
+	const char *refname);
 
 /**
  * Make the repository HEAD directly point to the Commit.
@@ -817,8 +817,8 @@ GIT_EXTERN(int) git_repository_set_head(
  * @return 0 on success, or an error code
  */
 GIT_EXTERN(int) git_repository_set_head_detached(
-	git_repository* repo,
-	const git_oid* commitish);
+	git_repository *repo,
+	const git_oid *commitish);
 
 /**
  * Make the repository HEAD directly point to the Commit.
@@ -854,7 +854,7 @@ GIT_EXTERN(int) git_repository_set_head_detached_from_annotated(
  * branch or an error code
  */
 GIT_EXTERN(int) git_repository_detach_head(
-	git_repository* repo);
+	git_repository *repo);
 
 /**
  * Repository state
diff --git a/include/git2/stash.h b/include/git2/stash.h
index 625e51b..795920e 100644
--- a/include/git2/stash.h
+++ b/include/git2/stash.h
@@ -200,7 +200,7 @@ GIT_EXTERN(int) git_stash_apply(
  */
 typedef int GIT_CALLBACK(git_stash_cb)(
 	size_t index,
-	const char* message,
+	const char *message,
 	const git_oid *stash_id,
 	void *payload);
 
diff --git a/src/blame.c b/src/blame.c
index 10e311a..a6ab43e 100644
--- a/src/blame.c
+++ b/src/blame.c
@@ -59,7 +59,7 @@ static bool hunk_starts_at_or_after_line(git_blame_hunk *hunk, size_t line)
 	return line <= hunk->final_start_line_number;
 }
 
-static git_blame_hunk* new_hunk(
+static git_blame_hunk *new_hunk(
 		size_t start,
 		size_t lines,
 		size_t orig_start,
@@ -84,7 +84,7 @@ static void free_hunk(git_blame_hunk *hunk)
 	git__free(hunk);
 }
 
-static git_blame_hunk* dup_hunk(git_blame_hunk *hunk)
+static git_blame_hunk *dup_hunk(git_blame_hunk *hunk)
 {
 	git_blame_hunk *newhunk = new_hunk(
 			hunk->final_start_line_number,
@@ -122,7 +122,7 @@ static void shift_hunks_by(git_vector *v, size_t start_line, int shift_by)
 	}
 }
 
-git_blame* git_blame__alloc(
+git_blame *git_blame__alloc(
 	git_repository *repo,
 	git_blame_options opts,
 	const char *path)
@@ -299,7 +299,7 @@ static int index_blob_lines(git_blame *blame)
     return blame->num_lines;
 }
 
-static git_blame_hunk* hunk_from_entry(git_blame__entry *e, git_blame *blame)
+static git_blame_hunk *hunk_from_entry(git_blame__entry *e, git_blame *blame)
 {
 	git_blame_hunk *h = new_hunk(
 			e->lno+1, e->num_lines, e->s_lno+1, e->suspect->path);
diff --git a/src/blame_git.c b/src/blame_git.c
index 073137a..3d514a1 100644
--- a/src/blame_git.c
+++ b/src/blame_git.c
@@ -429,7 +429,7 @@ static int paths_on_dup(void **old, void *new)
 	return -1;
 }
 
-static git_blame__origin* find_origin(
+static git_blame__origin *find_origin(
 		git_blame *blame,
 		git_commit *parent,
 		git_blame__origin *origin)
diff --git a/src/buffer.c b/src/buffer.c
index 794e1f1..ab2a613 100644
--- a/src/buffer.c
+++ b/src/buffer.c
@@ -670,7 +670,7 @@ int git_buf_join_n(git_buf *buf, char separator, int nbuf, ...)
 
 	va_start(ap, nbuf);
 	for (i = 0; i < nbuf; ++i) {
-		const char* segment;
+		const char *segment;
 		size_t segment_len;
 
 		segment = va_arg(ap, const char *);
@@ -702,7 +702,7 @@ int git_buf_join_n(git_buf *buf, char separator, int nbuf, ...)
 
 	va_start(ap, nbuf);
 	for (i = 0; i < nbuf; ++i) {
-		const char* segment;
+		const char *segment;
 		size_t segment_len;
 
 		segment = va_arg(ap, const char *);
diff --git a/src/clone.c b/src/clone.c
index e29a4aa..752df3b 100644
--- a/src/clone.c
+++ b/src/clone.c
@@ -265,7 +265,7 @@ static int update_head_to_branch(
 {
 	int retcode;
 	git_buf remote_branch_name = GIT_BUF_INIT;
-	git_reference* remote_ref = NULL;
+	git_reference *remote_ref = NULL;
 	git_buf default_branch = GIT_BUF_INIT;
 
 	GIT_ASSERT_ARG(remote);
diff --git a/src/commit_graph.c b/src/commit_graph.c
index 71e415e..f663fc5 100644
--- a/src/commit_graph.c
+++ b/src/commit_graph.c
@@ -728,7 +728,7 @@ int git_commit_graph_writer_add_revwalk(git_commit_graph_writer *w, git_revwalk 
 	git_oid id;
 	git_repository *repo = git_revwalk_repository(walk);
 	git_commit *commit;
-	struct packed_commit* packed_commit;
+	struct packed_commit *packed_commit;
 
 	while ((git_revwalk_next(&id, walk)) == 0) {
 		error = git_commit_lookup(&commit, repo, &id);
diff --git a/src/config.c b/src/config.c
index 7a5dadd..3251cd5 100644
--- a/src/config.c
+++ b/src/config.c
@@ -511,7 +511,7 @@ int git_config_backend_foreach_match(
 	void *payload)
 {
 	git_config_entry *entry;
-	git_config_iterator* iter;
+	git_config_iterator *iter;
 	git_regexp regex;
 	int error = 0;
 
diff --git a/src/config_file.c b/src/config_file.c
index 5267beb..3588e6b 100644
--- a/src/config_file.c
+++ b/src/config_file.c
@@ -164,7 +164,7 @@ out:
 	return error;
 }
 
-static void config_file_clear_includes(config_file_backend* cfg)
+static void config_file_clear_includes(config_file_backend *cfg)
 {
 	config_file *include;
 	uint32_t i;
@@ -1104,7 +1104,7 @@ static int write_on_eof(
 /*
  * This is pretty much the parsing, except we write out anything we don't have
  */
-static int config_file_write(config_file_backend *cfg, const char *orig_key, const char *key, const git_regexp *preg, const char* value)
+static int config_file_write(config_file_backend *cfg, const char *orig_key, const char *key, const git_regexp *preg, const char *value)
 
 {
 	char *orig_section = NULL, *section = NULL, *orig_name, *name, *ldot;
diff --git a/src/describe.c b/src/describe.c
index 3648cce..103d0da 100644
--- a/src/describe.c
+++ b/src/describe.c
@@ -391,7 +391,7 @@ static int show_suffix(
 	git_buf *buf,
 	int depth,
 	git_repository *repo,
-	const git_oid* id,
+	const git_oid *id,
 	unsigned int abbrev_size)
 {
 	int error, size = 0;
diff --git a/src/hash/sha1/sha1dc/sha1.c b/src/hash/sha1/sha1dc/sha1.c
index 86b8cc0..4d03c75 100644
--- a/src/hash/sha1/sha1dc/sha1.c
+++ b/src/hash/sha1/sha1dc/sha1.c
@@ -1710,7 +1710,7 @@ static void sha1_recompression_step(uint32_t step, uint32_t ihvin[5], uint32_t i
 
 
 
-static void sha1_process(SHA1_CTX* ctx, const uint32_t block[16])
+static void sha1_process(SHA1_CTX *ctx, const uint32_t block[16])
 {
 	unsigned i, j;
 	uint32_t ubc_dv_mask[DVMASKSIZE] = { 0xFFFFFFFF };
@@ -1762,7 +1762,7 @@ static void sha1_process(SHA1_CTX* ctx, const uint32_t block[16])
 	}
 }
 
-void SHA1DCInit(SHA1_CTX* ctx)
+void SHA1DCInit(SHA1_CTX *ctx)
 {
 	ctx->total = 0;
 	ctx->ihv[0] = 0x67452301;
@@ -1778,7 +1778,7 @@ void SHA1DCInit(SHA1_CTX* ctx)
 	ctx->callback = NULL;
 }
 
-void SHA1DCSetSafeHash(SHA1_CTX* ctx, int safehash)
+void SHA1DCSetSafeHash(SHA1_CTX *ctx, int safehash)
 {
 	if (safehash)
 		ctx->safe_hash = 1;
@@ -1787,7 +1787,7 @@ void SHA1DCSetSafeHash(SHA1_CTX* ctx, int safehash)
 }
 
 
-void SHA1DCSetUseUBC(SHA1_CTX* ctx, int ubc_check)
+void SHA1DCSetUseUBC(SHA1_CTX *ctx, int ubc_check)
 {
 	if (ubc_check)
 		ctx->ubc_check = 1;
@@ -1795,7 +1795,7 @@ void SHA1DCSetUseUBC(SHA1_CTX* ctx, int ubc_check)
 		ctx->ubc_check = 0;
 }
 
-void SHA1DCSetUseDetectColl(SHA1_CTX* ctx, int detect_coll)
+void SHA1DCSetUseDetectColl(SHA1_CTX *ctx, int detect_coll)
 {
 	if (detect_coll)
 		ctx->detect_coll = 1;
@@ -1803,7 +1803,7 @@ void SHA1DCSetUseDetectColl(SHA1_CTX* ctx, int detect_coll)
 		ctx->detect_coll = 0;
 }
 
-void SHA1DCSetDetectReducedRoundCollision(SHA1_CTX* ctx, int reduced_round_coll)
+void SHA1DCSetDetectReducedRoundCollision(SHA1_CTX *ctx, int reduced_round_coll)
 {
 	if (reduced_round_coll)
 		ctx->reduced_round_coll = 1;
@@ -1811,12 +1811,12 @@ void SHA1DCSetDetectReducedRoundCollision(SHA1_CTX* ctx, int reduced_round_coll)
 		ctx->reduced_round_coll = 0;
 }
 
-void SHA1DCSetCallback(SHA1_CTX* ctx, collision_block_callback callback)
+void SHA1DCSetCallback(SHA1_CTX *ctx, collision_block_callback callback)
 {
 	ctx->callback = callback;
 }
 
-void SHA1DCUpdate(SHA1_CTX* ctx, const char* buf, size_t len)
+void SHA1DCUpdate(SHA1_CTX *ctx, const char *buf, size_t len)
 {
 	unsigned left, fill;
 
diff --git a/src/merge.c b/src/merge.c
index 0e4bb58..191fb98 100644
--- a/src/merge.c
+++ b/src/merge.c
@@ -1151,7 +1151,7 @@ static void deletes_by_oid_free(git_oidmap *map) {
 	git_oidmap_free(map);
 }
 
-static int deletes_by_oid_enqueue(git_oidmap *map, git_pool* pool, const git_oid *id, size_t idx)
+static int deletes_by_oid_enqueue(git_oidmap *map, git_pool *pool, const git_oid *id, size_t idx)
 {
 	deletes_by_oid_queue *queue;
 	size_t *array_entry;
diff --git a/src/notes.c b/src/notes.c
index b9e1985..be52a5f 100644
--- a/src/notes.c
+++ b/src/notes.c
@@ -674,7 +674,7 @@ void git_note_free(git_note *note)
 }
 
 static int process_entry_path(
-	const char* entry_path,
+	const char *entry_path,
 	git_oid *annotated_object_id)
 {
 	int error = 0;
@@ -796,8 +796,8 @@ cleanup:
 }
 
 int git_note_next(
-	git_oid* note_id,
-	git_oid* annotated_id,
+	git_oid *note_id,
+	git_oid *annotated_id,
 	git_note_iterator *it)
 {
 	int error;
diff --git a/src/path.c b/src/path.c
index ec57322..c444b31 100644
--- a/src/path.c
+++ b/src/path.c
@@ -413,7 +413,7 @@ int git_path_to_dir(git_buf *path)
 	return git_buf_oom(path) ? -1 : 0;
 }
 
-void git_path_string_to_dir(char* path, size_t size)
+void git_path_string_to_dir(char *path, size_t size)
 {
 	size_t end = strlen(path);
 
diff --git a/src/path.h b/src/path.h
index dcf5652..de6ec8f 100644
--- a/src/path.h
+++ b/src/path.h
@@ -85,7 +85,7 @@ extern int git_path_to_dir(git_buf *path);
 /**
  * Ensure string has a trailing '/' if there is space for it.
  */
-extern void git_path_string_to_dir(char* path, size_t size);
+extern void git_path_string_to_dir(char *path, size_t size);
 
 /**
  * Taken from git.git; returns nonzero if the given path is "." or "..".
diff --git a/src/refdb_fs.c b/src/refdb_fs.c
index 0cb9255..24cb22f 100644
--- a/src/refdb_fs.c
+++ b/src/refdb_fs.c
@@ -764,7 +764,7 @@ static bool ref_is_available(
 static int reference_path_available(
 	refdb_fs_backend *backend,
 	const char *new_ref,
-	const char* old_ref,
+	const char *old_ref,
 	int force)
 {
 	size_t i;
diff --git a/src/refs.c b/src/refs.c
index 4900afa..8acfa84 100644
--- a/src/refs.c
+++ b/src/refs.c
@@ -249,7 +249,7 @@ int git_reference_dwim(git_reference **out, git_repository *repo, const char *re
 	git_reference *ref;
 	git_buf refnamebuf = GIT_BUF_INIT, name = GIT_BUF_INIT;
 
-	static const char* formatters[] = {
+	static const char *formatters[] = {
 		"%s",
 		GIT_REFS_DIR "%s",
 		GIT_REFS_TAGS_DIR "%s",
@@ -1246,7 +1246,7 @@ int git_reference_is_note(const git_reference *ref)
 	return git_reference__is_note(ref->name);
 }
 
-static int peel_error(int error, const git_reference *ref, const char* msg)
+static int peel_error(int error, const git_reference *ref, const char *msg)
 {
 	git_error_set(
 		GIT_ERROR_INVALID,
diff --git a/src/refspec.c b/src/refspec.c
index d0be29b..c72721a 100644
--- a/src/refspec.c
+++ b/src/refspec.c
@@ -359,7 +359,7 @@ int git_refspec__dwim_one(git_vector *out, git_refspec *spec, git_vector *refs)
 	git_remote_head key;
 	git_refspec *cur;
 
-	const char* formatters[] = {
+	const char *formatters[] = {
 		GIT_REFS_DIR "%s",
 		GIT_REFS_TAGS_DIR "%s",
 		GIT_REFS_HEADS_DIR "%s",
diff --git a/src/remote.c b/src/remote.c
index 7dddea9..154300b 100644
--- a/src/remote.c
+++ b/src/remote.c
@@ -677,7 +677,7 @@ int git_remote_set_instance_pushurl(git_remote *remote, const char *url)
 	return 0;
 }
 
-int git_remote_set_pushurl(git_repository *repo, const char *remote, const char* url)
+int git_remote_set_pushurl(git_repository *repo, const char *remote, const char *url)
 {
 	return set_url(repo, remote, CONFIG_PUSHURL_FMT, url);
 }
diff --git a/src/repository.c b/src/repository.c
index aae0c91..4b63a1f 100644
--- a/src/repository.c
+++ b/src/repository.c
@@ -2850,8 +2850,8 @@ cleanup:
 }
 
 int git_repository_set_head(
-	git_repository* repo,
-	const char* refname)
+	git_repository *repo,
+	const char *refname)
 {
 	git_reference *ref = NULL, *current = NULL, *new_head = NULL;
 	git_buf log_message = GIT_BUF_INIT;
@@ -2900,8 +2900,8 @@ cleanup:
 }
 
 int git_repository_set_head_detached(
-	git_repository* repo,
-	const git_oid* commitish)
+	git_repository *repo,
+	const git_oid *commitish)
 {
 	return detach(repo, commitish, NULL);
 }
@@ -2916,7 +2916,7 @@ int git_repository_set_head_detached_from_annotated(
 	return detach(repo, git_annotated_commit_id(commitish), commitish->description);
 }
 
-int git_repository_detach_head(git_repository* repo)
+int git_repository_detach_head(git_repository *repo)
 {
 	git_reference *old_head = NULL,	*new_head = NULL, *current = NULL;
 	git_object *object = NULL;
diff --git a/src/reset.c b/src/reset.c
index dfae91d..f21a620 100644
--- a/src/reset.c
+++ b/src/reset.c
@@ -22,7 +22,7 @@
 int git_reset_default(
 	git_repository *repo,
 	const git_object *target,
-	const git_strarray* pathspecs)
+	const git_strarray *pathspecs)
 {
 	git_object *commit = NULL;
 	git_tree *tree = NULL;
diff --git a/src/revparse.c b/src/revparse.c
index b0c312d..b4d5d47 100644
--- a/src/revparse.c
+++ b/src/revparse.c
@@ -14,7 +14,7 @@
 
 #include "git2.h"
 
-static int maybe_sha_or_abbrev(git_object** out, git_repository *repo, const char *spec, size_t speclen)
+static int maybe_sha_or_abbrev(git_object **out, git_repository *repo, const char *spec, size_t speclen)
 {
 	git_oid oid;
 
@@ -24,7 +24,7 @@ static int maybe_sha_or_abbrev(git_object** out, git_repository *repo, const cha
 	return git_object_lookup_prefix(out, repo, &oid, speclen, GIT_OBJECT_ANY);
 }
 
-static int maybe_sha(git_object** out, git_repository *repo, const char *spec)
+static int maybe_sha(git_object **out, git_repository *repo, const char *spec)
 {
 	size_t speclen = strlen(spec);
 
@@ -34,7 +34,7 @@ static int maybe_sha(git_object** out, git_repository *repo, const char *spec)
 	return maybe_sha_or_abbrev(out, repo, spec, speclen);
 }
 
-static int maybe_abbrev(git_object** out, git_repository *repo, const char *spec)
+static int maybe_abbrev(git_object **out, git_repository *repo, const char *spec)
 {
 	size_t speclen = strlen(spec);
 
@@ -310,7 +310,7 @@ cleanup:
 	return error;
 }
 
-static int handle_at_syntax(git_object **out, git_reference **ref, const char *spec, size_t identifier_len, git_repository* repo, const char *curly_braces_content)
+static int handle_at_syntax(git_object **out, git_reference **ref, const char *spec, size_t identifier_len, git_repository *repo, const char *curly_braces_content)
 {
 	bool is_numeric;
 	int parsed = 0, error = -1;
diff --git a/src/stash.c b/src/stash.c
index 8ee1273..49ea26f 100644
--- a/src/stash.c
+++ b/src/stash.c
@@ -56,7 +56,7 @@ static int append_abbreviated_oid(git_buf *out, const git_oid *b_commit)
 	return git_buf_oom(out) ? -1 : 0;
 }
 
-static int append_commit_description(git_buf *out, git_commit* commit)
+static int append_commit_description(git_buf *out, git_commit *commit)
 {
 	const char *summary = git_commit_summary(commit);
 	GIT_ERROR_CHECK_ALLOC(summary);
diff --git a/src/streams/openssl_legacy.c b/src/streams/openssl_legacy.c
index 1c1ff60..e61e6ef 100644
--- a/src/streams/openssl_legacy.c
+++ b/src/streams/openssl_legacy.c
@@ -36,7 +36,7 @@ int OPENSSL_init_ssl__legacy(uint64_t opts, const void *settings)
 	return 0;
 }
 
-BIO_METHOD* BIO_meth_new__legacy(int type, const char *name)
+BIO_METHOD *BIO_meth_new__legacy(int type, const char *name)
 {
 	BIO_METHOD *meth = git__calloc(1, sizeof(BIO_METHOD));
 	if (!meth) {
diff --git a/src/streams/openssl_legacy.h b/src/streams/openssl_legacy.h
index 1f74fd9..e6dae95 100644
--- a/src/streams/openssl_legacy.h
+++ b/src/streams/openssl_legacy.h
@@ -42,7 +42,7 @@
 #if defined(GIT_OPENSSL_LEGACY) || defined(GIT_OPENSSL_DYNAMIC)
 
 extern int OPENSSL_init_ssl__legacy(uint64_t opts, const void *settings);
-extern BIO_METHOD* BIO_meth_new__legacy(int type, const char *name);
+extern BIO_METHOD *BIO_meth_new__legacy(int type, const char *name);
 extern void BIO_meth_free__legacy(BIO_METHOD *biom);
 extern int BIO_meth_set_write__legacy(BIO_METHOD *biom, int (*write) (BIO *, const char *, int));
 extern int BIO_meth_set_read__legacy(BIO_METHOD *biom, int (*read) (BIO *, char *, int));
diff --git a/src/trailer.c b/src/trailer.c
index ca81fd0..61cdd1b 100644
--- a/src/trailer.c
+++ b/src/trailer.c
@@ -258,7 +258,7 @@ static size_t find_trailer_end(const char *buf, size_t len)
 	return len - ignore_non_trailer(buf, len);
 }
 
-static char *extract_trailer_block(const char *message, size_t* len)
+static char *extract_trailer_block(const char *message, size_t *len)
 {
 	size_t patch_start = find_patch_start(message);
 	size_t trailer_end = find_trailer_end(message, patch_start);
diff --git a/src/transports/ssh.c b/src/transports/ssh.c
index efa77a7..1b00be7 100644
--- a/src/transports/ssh.c
+++ b/src/transports/ssh.c
@@ -476,11 +476,11 @@ static int request_creds(git_credential **out, ssh_subtransport *t, const char *
 }
 
 static int _git_ssh_session_create(
-	LIBSSH2_SESSION** session,
+	LIBSSH2_SESSION **session,
 	git_stream *io)
 {
 	int rc = 0;
-	LIBSSH2_SESSION* s;
+	LIBSSH2_SESSION *s;
 	git_socket_stream *socket = GIT_CONTAINER_OF(io, git_socket_stream, parent);
 
 	GIT_ASSERT_ARG(session);
@@ -521,8 +521,8 @@ static int _git_ssh_setup_conn(
 	size_t i;
 	ssh_stream *s;
 	git_credential *cred = NULL;
-	LIBSSH2_SESSION* session=NULL;
-	LIBSSH2_CHANNEL* channel=NULL;
+	LIBSSH2_SESSION *session=NULL;
+	LIBSSH2_CHANNEL *channel=NULL;
 
 	t->current_stream = NULL;
 
diff --git a/src/transports/winhttp.c b/src/transports/winhttp.c
index 178773a..f4801a4 100644
--- a/src/transports/winhttp.c
+++ b/src/transports/winhttp.c
@@ -250,7 +250,7 @@ static int acquire_fallback_cred(
 		hCoInitResult = CoInitializeEx(NULL, COINIT_MULTITHREADED);
 
 		if (SUCCEEDED(hCoInitResult) || hCoInitResult == RPC_E_CHANGED_MODE) {
-			IInternetSecurityManager* pISM;
+			IInternetSecurityManager *pISM;
 
 			/* And if the target URI is in the My Computer, Intranet, or Trusted zones */
 			if (SUCCEEDED(CoCreateInstance(&CLSID_InternetSecurityManager, NULL,
diff --git a/src/win32/findfile.c b/src/win32/findfile.c
index f541a03..40d2d51 100644
--- a/src/win32/findfile.c
+++ b/src/win32/findfile.c
@@ -49,7 +49,7 @@ static int win32_path_to_8(git_buf *dest, const wchar_t *src)
 	return git_buf_sets(dest, utf8_path);
 }
 
-static wchar_t* win32_walkpath(wchar_t *path, wchar_t *buf, size_t buflen)
+static wchar_t *win32_walkpath(wchar_t *path, wchar_t *buf, size_t buflen)
 {
 	wchar_t term, *base = path;
 
diff --git a/src/win32/posix.h b/src/win32/posix.h
index f115088..87c6b43 100644
--- a/src/win32/posix.h
+++ b/src/win32/posix.h
@@ -23,7 +23,7 @@ typedef SOCKET GIT_SOCKET;
 
 extern int p_fstat(int fd, struct stat *buf);
 extern int p_lstat(const char *file_name, struct stat *buf);
-extern int p_stat(const char* path, struct stat *buf);
+extern int p_stat(const char *path, struct stat *buf);
 
 extern int p_utimes(const char *filename, const struct p_timeval times[2]);
 extern int p_futimes(int fd, const struct p_timeval times[2]);
@@ -38,15 +38,15 @@ extern char *p_realpath(const char *orig_path, char *buffer);
 
 extern int p_recv(GIT_SOCKET socket, void *buffer, size_t length, int flags);
 extern int p_send(GIT_SOCKET socket, const void *buffer, size_t length, int flags);
-extern int p_inet_pton(int af, const char* src, void* dst);
+extern int p_inet_pton(int af, const char *src, void* dst);
 
 extern int p_vsnprintf(char *buffer, size_t count, const char *format, va_list argptr);
 extern int p_snprintf(char *buffer, size_t count, const char *format, ...) GIT_FORMAT_PRINTF(3, 4);
 extern int p_mkstemp(char *tmp_path);
-extern int p_chdir(const char* path);
-extern int p_chmod(const char* path, mode_t mode);
-extern int p_rmdir(const char* path);
-extern int p_access(const char* path, mode_t mode);
+extern int p_chdir(const char *path);
+extern int p_chmod(const char *path, mode_t mode);
+extern int p_rmdir(const char *path);
+extern int p_access(const char *path, mode_t mode);
 extern int p_ftruncate(int fd, off64_t size);
 
 /* p_lstat is almost but not quite POSIX correct.  Specifically, the use of
diff --git a/src/win32/posix_w32.c b/src/win32/posix_w32.c
index 7fcc472..66d12cf 100644
--- a/src/win32/posix_w32.c
+++ b/src/win32/posix_w32.c
@@ -690,7 +690,7 @@ static int getfinalpath_w(
 	return (int)git_win32_path_remove_namespace(dest, dwChars);
 }
 
-static int follow_and_lstat_link(git_win32_path path, struct stat* buf)
+static int follow_and_lstat_link(git_win32_path path, struct stat *buf)
 {
 	git_win32_path target_w;
 
@@ -716,7 +716,7 @@ int p_fstat(int fd, struct stat *buf)
 	return 0;
 }
 
-int p_stat(const char* path, struct stat* buf)
+int p_stat(const char *path, struct stat *buf)
 {
 	git_win32_path path_w;
 	int len;
@@ -733,7 +733,7 @@ int p_stat(const char* path, struct stat* buf)
 	return 0;
 }
 
-int p_chdir(const char* path)
+int p_chdir(const char *path)
 {
 	git_win32_path buf;
 
@@ -743,7 +743,7 @@ int p_chdir(const char* path)
 	return _wchdir(buf);
 }
 
-int p_chmod(const char* path, mode_t mode)
+int p_chmod(const char *path, mode_t mode)
 {
 	git_win32_path buf;
 
@@ -753,7 +753,7 @@ int p_chmod(const char* path, mode_t mode)
 	return _wchmod(buf, mode);
 }
 
-int p_rmdir(const char* path)
+int p_rmdir(const char *path)
 {
 	git_win32_path buf;
 	int error;
@@ -873,7 +873,7 @@ int p_mkstemp(char *tmp_path)
 	return p_open(tmp_path, O_RDWR | O_CREAT | O_EXCL, 0744); /* -V536 */
 }
 
-int p_access(const char* path, mode_t mode)
+int p_access(const char *path, mode_t mode)
 {
 	git_win32_path buf;