From ede84ffa426edb950c4ec4f89833c85475a1c64f Mon Sep 17 00:00:00 2001 From: Garret Rieger Date: Thu, 1 Feb 2018 17:17:36 -0800 Subject: [PATCH] Whitespace --- util/hb-subset.cc | 36 ++++++++++++++++++------------------ 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/util/hb-subset.cc b/util/hb-subset.cc index 5aafbe194..4beb6a1c0 100644 --- a/util/hb-subset.cc +++ b/util/hb-subset.cc @@ -15,7 +15,7 @@ main (int argc, char **argv) int exit_code = 0; if (argc != 4) { - fprintf(stderr, "Must have 4 args\n"); + fprintf(stderr, "Must have 4 args\n"); exit(1); } @@ -39,26 +39,26 @@ main (int argc, char **argv) perror("Unable to fstat"); } - if (mapped_file != MAP_FAILED) { - hb_blob_t *font_blob = hb_blob_create(static_cast(mapped_file), - stat.st_size, - HB_MEMORY_MODE_READONLY, nullptr, - nullptr); + if (mapped_file != MAP_FAILED) { + hb_blob_t *font_blob = hb_blob_create(static_cast(mapped_file), + stat.st_size, + HB_MEMORY_MODE_READONLY, nullptr, + nullptr); - fd_out = open(argv[2], O_CREAT | O_WRONLY, S_IRWXU); - if (fd_out != -1) { - ssize_t bytes_written = write(fd_out, mapped_file, stat.st_size); - if (bytes_written == -1) { - perror("Unable to write output file"); - exit_code = 1; - } else if (bytes_written != stat.st_size) { - fprintf(stderr, "Wrong number of bytes written"); - exit_code = 1; - } - } else { - perror("Unable to open output file"); + fd_out = open(argv[2], O_CREAT | O_WRONLY, S_IRWXU); + if (fd_out != -1) { + ssize_t bytes_written = write(fd_out, mapped_file, stat.st_size); + if (bytes_written == -1) { + perror("Unable to write output file"); + exit_code = 1; + } else if (bytes_written != stat.st_size) { + fprintf(stderr, "Wrong number of bytes written"); exit_code = 1; } + } else { + perror("Unable to open output file"); + exit_code = 1; + } } if (mapped_file != MAP_FAILED) {