.
This is for our network, and we want to allow music videos, but not full movies, I want the client to only list files that are below 75 meg.
I know it should be in the shareManager.cpp, and possibly in
"ShareManager::Directory* ShareManager::buildTree..."
But I can't seem to get it to work.. Can someone please point me in the right direction or pass along the proper code?
Thanks,
Bobby
Tech help
Moderator: Moderators
-
- DC++ Contributor
- Posts: 3212
- Joined: 2003-01-07 21:46
- Location: .pa.us
Re: Tech help
Hola Bobby.ZPoc wrote:This is for our network, and we want to allow music videos, but not full movies, I want the client to only list files that are below 75 meg.
I know it should be in the shareManager.cpp, and possibly in
"ShareManager::Directory* ShareManager::buildTree..."
But I can't seem to get it to work.. Can someone please point me in the right direction or pass along the proper code?
I'm sure one of the kind ops will move this to the Programmer's Help section
This'll probably do you just fine:
Code: Select all
--- ShareManager.cpp Tue Feb 25 18:32:54 2003
+++ ShareManager.cpp.mod.cpp Wed Feb 26 15:58:40 2003
@@ -250,11 +250,13 @@
// Not a directory, assume it's a file...make sure we're not sharing the setting
s file...
if(Util::stricmp(name.c_str(), "DCPlusPlus.xml") != 0 && name.find('$') == string::npos) {
+ if(((int64_t)data.nFileSizeLow | ((int64_t)data.nFileSizeHigh)<<32) <= 75 *1024*1024) {
dir->addSearchType(getMask(name));
dir->addType(getType(name));
dir->files[name] = (int64_t)data.nFileSizeLow | ((int64_t)data.nFileSizeHigh)<<32;
dir->size+=(int64_t)data.nFileSizeLow | ((int64_t)data.nFileSizeHigh)<<32;
}
+ }
}
}
} while(FindNextFile(hFind, &data));
- Todd
Re: Tech help
alrite..GargoyleMT wrote:I'm sure one of the kind ops will move this to the Programmer's Help section
oops
Todd, thanks for helping me out, can't belive I missed it.
Bobby
Ps, sorry for putting it in the wrong forum
Bobby
Ps, sorry for putting it in the wrong forum
-
- DC++ Contributor
- Posts: 3212
- Joined: 2003-01-07 21:46
- Location: .pa.us
Re: Tech help
PS. Thank you!aDe wrote:alrite..GargoyleMT wrote:I'm sure one of the kind ops will move this to the Programmer's Help section