From: Jay Freeman (saurik) Date: Fri, 13 Nov 2015 08:01:48 +0000 (-0800) Subject: Allow -K argument to not specify a key (why not?). X-Git-Tag: v2.1.0~59 X-Git-Url: https://git.saurik.com/ldid.git/commitdiff_plain/d73a3d58d0aefb576efc29af4d4eb3c13c3b0503 Allow -K argument to not specify a key (why not?). --- diff --git a/ldid.cpp b/ldid.cpp index 0c52fa4..461433f 100644 --- a/ldid.cpp +++ b/ldid.cpp @@ -2203,7 +2203,8 @@ int main(int argc, char *argv[]) { break; case 'K': - key.open(argv[argi] + 2, O_RDONLY, PROT_READ, MAP_PRIVATE); + if (argv[argi][2] != '\0') + key.open(argv[argi] + 2, O_RDONLY, PROT_READ, MAP_PRIVATE); break; #ifndef LDID_NOFLAGT