Skip to content

Commit

Permalink
Fix some warnings from scan-obj
Browse files Browse the repository at this point in the history
  • Loading branch information
nemequ committed Jul 1, 2016
1 parent 01b7e5c commit 613ffed
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 4 deletions.
6 changes: 3 additions & 3 deletions examples/simple.c
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ int main (int argc, char** argv) {
if (res != SQUASH_OK) {
fprintf (stderr, "Unable to compress data [%d]: %s\n",
res, squash_status_to_string (res));
return EXIT_FAILURE;
exit (EXIT_FAILURE);
}

fprintf (stdout, "Compressed a %u byte buffer to %u bytes.\n",
Expand All @@ -52,7 +52,7 @@ int main (int argc, char** argv) {
if (res != SQUASH_OK) {
fprintf (stderr, "Unable to decompress data [%d]: %s\n",
res, squash_status_to_string (res));
return EXIT_FAILURE;
exit (EXIT_FAILURE);
}

/* Notice that we didn't compress the *NULL* byte at the end of the
Expand All @@ -61,7 +61,7 @@ int main (int argc, char** argv) {

if (strcmp (decompressed, uncompressed) != 0) {
fprintf (stderr, "Bad decompressed data.\n");
return EXIT_FAILURE;
exit (EXIT_FAILURE);
}

fprintf (stdout, "Successfully decompressed.\n");
Expand Down
1 change: 1 addition & 0 deletions squash/squash-options.c
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,7 @@ squash_options_find (SquashOptions* options, SquashCodec* codec, const char* key
if (codec == NULL) {
assert (options != NULL);
codec = options->codec;
assert (codec != NULL);
}

const SquashOptionInfo* info = squash_codec_get_option_info (codec);
Expand Down
1 change: 1 addition & 0 deletions tests/file.c
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,7 @@ squash_test_splice_full(const MunitParameter params[], void* user_data) {
/* Start in the middle of the file, just to make sure it works. */
offset = (size_t) munit_rand_int_range (1, sizeof(offset_buf));
bytes_written = fwrite (offset_buf, 1, offset, compressed);
munit_assert_size (bytes_written, ==, offset);
munit_assert_int (ftello (compressed), ==, offset);

SquashStatus res = squash_splice (data->codec, SQUASH_STREAM_COMPRESS, compressed, uncompressed, 0, NULL);
Expand Down
2 changes: 1 addition & 1 deletion tests/munit
Submodule munit updated 2 files
+221 −191 munit.c
+15 −1 munit.h

0 comments on commit 613ffed

Please sign in to comment.