48
if (debug)
49
fprintf(stderr, "Debug: Remote helper: -> %s", buffer->buf);
50
if (write_in_full(helper->helper->in, buffer->buf, buffer->len) < 0)
51
- die_errno("Full write to remote helper failed");
51
+ die_errno("full write to remote helper failed");
52
}
53
54
static int recvline_fh(FILE *helper, struct strbuf *buffer)
77
if (debug)
78
fprintf(stderr, "Debug: Remote helper: -> %s", str);
79
if (write_in_full(fd, str, strlen(str)) < 0)
80
- die_errno("Full write to remote helper failed");
80
+ die_errno("full write to remote helper failed");
81
}
82
83
static const char *remove_ext_force(const char *url)
129
130
code = start_command(helper);
131
if (code < 0 && errno == ENOENT)
132
- die("Unable to find remote helper for '%s'", data->name);
132
+ die("unable to find remote helper for '%s'", data->name);
133
else if (code != 0)
134
exit(code);
135
145
*/
146
duped = dup(helper->out);
147
if (duped < 0)
148
- die_errno("Can't dup helper output fd");
148
+ die_errno("can't dup helper output fd");
149
data->out = xfdopen(duped, "r");
150
151
write_constant(helper->in, "capabilities\n");
196
} else if (starts_with(capname, "no-private-update")) {
197
data->no_private_update = 1;
198
} else if (mandatory) {
199
- die("Unknown mandatory capability %s. This remote "
200
- "helper probably needs newer version of Git.",
199
+ die("unknown mandatory capability %s; this remote "
200
+ "helper probably needs newer version of Git",
201
capname);
202
}
203
}
204
if (!data->rs.nr && (data->import || data->bidi_import || data->export)) {
205
- warning("This remote helper should implement refspec capability.");
205
+ warning("this remote helper should implement refspec capability");
206
}
207
strbuf_release(&buf);
208
if (debug)
476
get_helper(transport);
477
478
if (get_importer(transport, &fastimport))
479
- die("Couldn't run fast-import");
479
+ die("couldn't run fast-import");
480
481
for (i = 0; i < nr_heads; i++) {
482
posn = to_fetch[i];
499
*/
500
501
if (finish_command(&fastimport))
502
- die("Error while running fast-import");
502
+ die("error while running fast-import");
503
504
/*
505
* The fast-import stream of a remote helper that advertises
528
private = xstrdup(name);
529
if (private) {
530
if (read_ref(private, &posn->old_oid) < 0)
531
- die("Could not read ref %s", private);
531
+ die("could not read ref %s", private);
532
free(private);
533
}
534
}
554
*/
555
duped = dup(helper->out);
556
if (duped < 0)
557
- die_errno("Can't dup helper output fd");
557
+ die_errno("can't dup helper output fd");
558
input = xfdopen(duped, "r");
559
setvbuf(input, NULL, _IONBF, 0);
560
573
fprintf(stderr, "Debug: Falling back to dumb "
574
"transport.\n");
575
} else {
576
- die("Unknown response to connect: %s",
576
+ die("unknown response to connect: %s",
577
cmdbuf->buf);
578
}
579
595
if (strcmp(name, exec)) {
596
int r = set_helper_option(transport, "servpath", exec);
597
if (r > 0)
598
- warning("Setting remote service path not supported by protocol.");
598
+ warning("setting remote service path not supported by protocol");
599
else if (r < 0)
600
- warning("Invalid remote service path.");
600
+ warning("invalid remote service path");
601
}
602
603
if (data->connect) {
640
/* Get_helper so connect is inited. */
641
get_helper(transport);
642
if (!data->connect)
643
- die("Operation not supported by protocol.");
643
+ die("operation not supported by protocol");
644
645
if (!process_connect_service(transport, name, exec))
646
- die("Can't connect to subservice %s.", name);
646
+ die("can't connect to subservice %s", name);
647
648
fd[0] = data->helper->out;
649
fd[1] = data->helper->in;
978
}
979
980
if (get_exporter(transport, &exporter, &revlist_args))
981
- die("Couldn't run fast-export");
981
+ die("couldn't run fast-export");
982
983
string_list_clear(&revlist_args, 1);
984
985
if (finish_command(&exporter))
986
- die("Error while running fast-export");
986
+ die("error while running fast-export");
987
if (push_update_refs_status(data, remote_refs, flags))
988
return 1;
989
1070
1071
eov = strchr(buf.buf, ' ');
1072
if (!eov)
1073
- die("Malformed response in ref list: %s", buf.buf);
1073
+ die("malformed response in ref list: %s", buf.buf);
1074
eon = strchr(eov + 1, ' ');
1075
*eov = '\0';
1076
if (eon)
1084
if (has_attribute(eon + 1, "unchanged")) {
1085
(*tail)->status |= REF_STATUS_UPTODATE;
1086
if (read_ref((*tail)->name, &(*tail)->old_oid) < 0)
1087
- die(_("Could not read ref %s"),
1087
+ die(_("could not read ref %s"),
1088
(*tail)->name);
1089
}
1090
}
1322
err = pthread_create(>p_thread, NULL, udt_copy_task_routine,
1323
&s->gtp);
1324
if (err)
1325
- die("Can't start thread for copying data: %s", strerror(err));
1325
+ die("can't start thread for copying data: %s", strerror(err));
1326
err = pthread_create(&ptg_thread, NULL, udt_copy_task_routine,
1327
&s->ptg);
1328
if (err)
1329
- die("Can't start thread for copying data: %s", strerror(err));
1329
+ die("can't start thread for copying data: %s", strerror(err));
1330
1331
ret |= tloop_join(gtp_thread, "Git to program copy");
1332
ret |= tloop_join(ptg_thread, "Program to git copy");
1385
/* Fork thread #1: git to program. */
1386
pid1 = fork();
1387
if (pid1 < 0)
1388
- die_errno("Can't start thread for copying data");
1388
+ die_errno("can't start thread for copying data");
1389
else if (pid1 == 0) {
1390
udt_kill_transfer(&s->ptg);
1391
exit(udt_copy_task_routine(&s->gtp) ? 0 : 1);
1394
/* Fork thread #2: program to git. */
1395
pid2 = fork();
1396
if (pid2 < 0)
1397
- die_errno("Can't start thread for copying data");
1397
+ die_errno("can't start thread for copying data");
1398
else if (pid2 == 0) {
1399
udt_kill_transfer(&s->gtp);
1400
exit(udt_copy_task_routine(&s->ptg) ? 0 : 1);