- if (get_sha1_hex(arg, sha1) < 0) {
- fprintf(stderr, "read-tree [-m] <sha1>\n");
- goto out;
- }
- if (read_tree(sha1, "", 0) < 0) {
- fprintf(stderr, "failed to unpack tree object %s\n", arg);
- goto out;
- }
+ if (get_sha1_hex(arg, sha1) < 0)
+ usage("read-tree [-m] <sha1>");
+ if (read_tree(sha1, "", 0) < 0)
+ die("failed to unpack tree object %s", arg);