Browse Source

fix minor integer casting issues

pull/162/head
Antonio SJ Musumeci 9 years ago
parent
commit
1c7de2d83e
  1. 2
      src/config.cpp
  2. 4
      src/getxattr.cpp

2
src/config.cpp

@ -33,7 +33,7 @@
#include "rwlock.hpp" #include "rwlock.hpp"
#include "fs.hpp" #include "fs.hpp"
#define MINFREESPACE_DEFAULT (4294967295)
#define MINFREESPACE_DEFAULT (4294967295ULL)
#define POLICYINIT(X) X(policies[FuseFunc::Enum::X]) #define POLICYINIT(X) X(policies[FuseFunc::Enum::X])
using std::string; using std::string;

4
src/getxattr.cpp

@ -117,8 +117,10 @@ _getxattr_controlfile_minfreespace(const Config &config,
string &attrvalue) string &attrvalue)
{ {
char buf[64]; char buf[64];
unsigned long long minfreespace;
snprintf(buf,sizeof(buf),"%li",config.minfreespace);
minfreespace = (unsigned long long)config.minfreespace;
snprintf(buf,sizeof(buf),"%llu",minfreespace);
attrvalue = buf; attrvalue = buf;
} }

Loading…
Cancel
Save