Skip to content

Commit

Permalink
SDFS Windows updates
Browse files Browse the repository at this point in the history
  • Loading branch information
opendedup committed Mar 5, 2016
1 parent eaa5045 commit dafaf96
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 0 deletions.
1 change: 1 addition & 0 deletions install-packages/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,4 @@
/sdfs-3.0.2-1.x86_64.rpm
/sdfs_3.0.4_amd64.deb
/sdfs-3.0.4-1.x86_64.rpm
/SDFS-3.1.0-Setup.exe
Binary file modified windows-exe/SDFSCli.sdf
Binary file not shown.
6 changes: 6 additions & 0 deletions windows-exe/mountsdfs/mountsdfs.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,7 @@ int _tmain(int argc, TCHAR *argv[])

TCHAR configFile[512];
__int64 mem = 256;
__int64 bsize = 60;
for (int i = 1; i < argc; i++) {
if (!_tcsncmp(argv[i], _T("-mem"), 4)) {
mem = _ttoi(argv[i + 1]);
Expand Down Expand Up @@ -174,11 +175,16 @@ int _tmain(int argc, TCHAR *argv[])
doc.Parse(contents.c_str());
if (doc.ErrorID() == 0) {
string ssz = string(doc.FirstChildElement("subsystem-config")->FirstChildElement("local-chunkstore")->Attribute("allocation-size"));
string bssz = string(doc.FirstChildElement("subsystem-config")->FirstChildElement("local-chunkstore")->FirstChildElement("extended-config")->Attribute("io-threads"));
std::stringstream sstr(ssz);
std::stringstream bstr(bssz);
__int64 sz;
__int64 bsz;
sstr >> sz;
bstr >> bsz;
long gb = sz / (1073741824);
mem += .4 * gb;
mem += bsize * bsz;
//cout << sz << " asz= " << gb << " mem=" << mem << "\n";
}
else {
Expand Down

0 comments on commit dafaf96

Please sign in to comment.