replace ec3_reader and ec3_writer with a unified image and tag io interface

This commit is contained in:
2025-02-23 20:52:59 +00:00
parent 2e4ee5c1b6
commit 9aeae388a4
32 changed files with 3458 additions and 264 deletions

View File

@@ -12,8 +12,6 @@ static enum ec3_status identifier_from_int_string(
uint64_t *out,
int base)
{
/* skip leading '0x' */
s += 2;
char *ep = NULL;
uint64_t v = strtoull(s, &ep, base);
@@ -39,7 +37,7 @@ static bool is_base10_string(const char *s)
enum ec3_status ec3_identifier_from_string(const char *s, uint64_t *out)
{
if (s[0] == '0' && s[1] == 'x') {
return identifier_from_int_string(s, out, 16);
return identifier_from_int_string(s + 2, out, 16);
}
if (is_base10_string(s)) {