aboutsummaryrefslogtreecommitdiff
path: root/bp.c
diff options
context:
space:
mode:
authorBruce Hill <bruce@bruce-hill.com>2021-05-31 13:25:38 -0700
committerBruce Hill <bruce@bruce-hill.com>2021-05-31 13:25:38 -0700
commitc89fd1db426b05e372206661a2dfa455d4e53c2d (patch)
tree0482cab7573376214c05fa60d7e6b01cf1738226 /bp.c
parenta67a25704406456cbd1d84115892c9cb5187b06c (diff)
Added lots of extra compiler flags
Diffstat (limited to 'bp.c')
-rw-r--r--bp.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/bp.c b/bp.c
index ec2b180..99d0119 100644
--- a/bp.c
+++ b/bp.c
@@ -451,7 +451,7 @@ static int process_git_files(def_t *defs, pat_t *pattern, int argc, char *argv[]
if (child == -1)
err(EXIT_FAILURE, "Failed to fork");
if (child == 0) {
- char **git_args = memcheck(calloc((size_t)(2+argc+1), sizeof(char*)));
+ const char **git_args = memcheck(calloc((size_t)(2+argc+1), sizeof(char*)));
int g = 0;
git_args[g++] = "git";
git_args[g++] = "ls-files";
@@ -460,7 +460,7 @@ static int process_git_files(def_t *defs, pat_t *pattern, int argc, char *argv[]
err(EXIT_FAILURE, "Failed to hook up pipe to stdout");
if (close(fds[STDIN_FILENO]) != 0)
err(EXIT_FAILURE, "Failed to close read end of pipe");
- (void)execvp("git", git_args);
+ (void)execvp("git", (char**)git_args);
_exit(EXIT_FAILURE);
}
if (close(fds[STDOUT_FILENO]) != 0)