]> git.ipfire.org Git - thirdparty/ccache.git/commitdiff
Don't compare booleans with 0
authorJoel Rosdahl <joel@rosdahl.net>
Sun, 12 Sep 2010 14:37:38 +0000 (16:37 +0200)
committerJoel Rosdahl <joel@rosdahl.net>
Sun, 12 Sep 2010 14:37:38 +0000 (16:37 +0200)
ccache.c

index c8c65892d5120577169041304c8a965a1651f364..2a4ba22db8ae98aaf3b7665f70d5e90f97938db0 100644 (file)
--- a/ccache.c
+++ b/ccache.c
@@ -995,7 +995,7 @@ from_cache(enum fromcache_call_mode mode, bool put_object_in_manifest)
        } else {
                unlink(output_obj);
                /* only make a hardlink if the cache file is uncompressed */
-               if (getenv("CCACHE_HARDLINK") && file_is_compressed(cached_obj) == 0) {
+               if (getenv("CCACHE_HARDLINK") && !file_is_compressed(cached_obj)) {
                        ret = link(cached_obj, output_obj);
                } else {
                        ret = copy_file(cached_obj, output_obj, 0);
@@ -1025,7 +1025,7 @@ from_cache(enum fromcache_call_mode mode, bool put_object_in_manifest)
        if (produce_dep_file) {
                unlink(output_dep);
                /* only make a hardlink if the cache file is uncompressed */
-               if (getenv("CCACHE_HARDLINK") && file_is_compressed(cached_dep) == 0) {
+               if (getenv("CCACHE_HARDLINK") && !file_is_compressed(cached_dep)) {
                        ret = link(cached_dep, output_dep);
                } else {
                        ret = copy_file(cached_dep, output_dep, 0);