fix build warnings with type mismatches and base check helpers

Building with base headers in a SLOT-ed setup exposes build warnings
(which causes failures due to -Werror).  One such example:

In file included from extent_writer.h:9:0,
                 from bzip_extent_writer.h:10,
                 from bzip_extent_writer.cc:5:
.../base/logging.h: In function 'std::string* logging::CheckEQImpl(const t1&, const t2&, const char*)
                                 [with t1 = unsigned int, t2 = int, std::string = std::basic_string<char>]':
bzip_extent_writer.cc:53:7:   instantiated from here
.../base/logging.h:512:1: error: comparison between signed and unsigned integer expressions [-Werror=sign-compare]
cc1plus: all warnings being treated as errors

Explicitly cast the constants to avoid these.

BUG=chromium-os:16623
TEST=`emerge-x86-alex update_engine` builds

Change-Id: If3cc4e85fa54862b14305f9d045c73b5575efaa0
Reviewed-on: https://gerrit.chromium.org/gerrit/16035
Reviewed-by: Gilad Arnold <garnold@chromium.org>
Tested-by: Mike Frysinger <vapier@chromium.org>
Commit-Ready: Mike Frysinger <vapier@chromium.org>
diff --git a/metadata.cc b/metadata.cc
index 7dfc787..6b52f29 100644
--- a/metadata.cc
+++ b/metadata.cc
@@ -151,7 +151,7 @@
       TEST_AND_RETURN_FALSE(ComputeMetadataBsdiff(old_data,
                                                   new_data,
                                                   &bsdiff_delta));
-      CHECK_GT(bsdiff_delta.size(), 0);
+      CHECK_GT(bsdiff_delta.size(), static_cast<vector<char>::size_type>(0));
 
       if (bsdiff_delta.size() < current_best_size) {
         op.set_type(DeltaArchiveManifest_InstallOperation_Type_BSDIFF);