clean up warnings from msvc

This commit is contained in:
Tianqi Chen
2014-08-25 11:01:21 -07:00
parent 4f0b0d2c88
commit ca0b008fb0
20 changed files with 217 additions and 46 deletions

View File

@@ -179,7 +179,7 @@ class DMatrixSimple : public DataMatrix {
* \param savebuffer whether do save binary buffer if it is text
*/
inline void CacheLoad(const char *fname, bool silent = false, bool savebuffer = true) {
int len = strlen(fname);
size_t len = strlen(fname);
if (len > 8 && !strcmp(fname + len - 7, ".buffer")) {
if (!this->LoadBinary(fname, silent)) {
utils::Error("can not open file \"%s\"", fname);