• Jeff King's avatar
    argv-array: add detach function · b992657e
    Jeff King authored
    The usual pattern for an argv array is to initialize it,
    push in some strings, and then clear it when done. Very
    occasionally, though, we must do other exotic things with
    the memory, like freeing the list but keeping the strings.
    Let's provide a detach function so that callers can make use
    of our API to build up the array, and then take ownership of
    Signed-off-by: default avatarJeff King <[email protected]>
    Signed-off-by: default avatarJunio C Hamano <[email protected]>
argv-array.h 689 Bytes