diff options
Diffstat (limited to 'src/blob.c')
-rw-r--r-- | src/blob.c | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -18,6 +18,9 @@ char *apk_blob_cstr(apk_blob_t blob) { char *cstr; + if (blob.ptr == NULL) + return strdup(""); + if (blob.ptr[blob.len-1] == 0) return strdup(blob.ptr); |