struct todo_item {
enum todo_command command;
struct commit *commit;
+ const char *arg;
+ int arg_len;
size_t offset_in_buf;
};
status = get_sha1(bol, commit_sha1);
*end_of_object_name = saved;
+ item->arg = end_of_object_name + strspn(end_of_object_name, " \t");
+ item->arg_len = (int)(eol - item->arg);
+
if (status < 0)
return -1;
item->command = command;
item->commit = commit;
+ item->arg = NULL;
+ item->arg_len = 0;
item->offset_in_buf = todo_list->buf.len;
subject_len = find_commit_subject(commit_buffer, &subject);
strbuf_addf(&todo_list->buf, "%s %s %.*s\n", command_string,