mirror of
https://github.com/git/git.git
synced 2025-12-12 20:36:24 +01:00
Merge branch 'cc/fast-import-export-signature-names'
Clean up the way how signature on commit objects are exported to and imported from fast-import stream. * cc/fast-import-export-signature-names: fast-(import|export): improve on commit signature output format
This commit is contained in:
@@ -144,6 +144,18 @@ static struct gpg_format *get_format_by_sig(const char *sig)
|
||||
return NULL;
|
||||
}
|
||||
|
||||
const char *get_signature_format(const char *buf)
|
||||
{
|
||||
struct gpg_format *format = get_format_by_sig(buf);
|
||||
return format ? format->name : "unknown";
|
||||
}
|
||||
|
||||
int valid_signature_format(const char *format)
|
||||
{
|
||||
return (!!get_format_by_name(format) ||
|
||||
!strcmp(format, "unknown"));
|
||||
}
|
||||
|
||||
void signature_check_clear(struct signature_check *sigc)
|
||||
{
|
||||
FREE_AND_NULL(sigc->payload);
|
||||
|
||||
Reference in New Issue
Block a user