Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 2ab5a70b authored by Elliott Hughes's avatar Elliott Hughes
Browse files

ziptool: fix unknown long options.

Previously an unknown long option would cause a crash as we ran off the
end of the array.

Test: `ziptool unzip --unknown`
Change-Id: I7a7b6ac4a0fa157c111f936e837c20143cef9e28
parent dc4bd271
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -448,6 +448,7 @@ int main(int argc, char* argv[]) {

  static const struct option opts[] = {
      {"help", no_argument, 0, 'h'},
      {},
  };

  if (role == kUnzip) {