diff options
| author | Tatsuhiro Tsujikawa <tatsuhiro.t@gmail.com> | 2009-12-07 12:49:19 +0000 |
|---|---|---|
| committer | Tatsuhiro Tsujikawa <tatsuhiro.t@gmail.com> | 2009-12-07 12:49:19 +0000 |
| commit | 58bb1fa266d7d96c88b05a2c4727bdcde812e639 (patch) | |
| tree | 4fddaa3cb109507ebbbcff9850cf9217d539e32c /src/util.h | |
| parent | 32f25fdef43afcad0ea56f82de273bdf0d4dd729 (diff) | |
2009-12-07 Tatsuhiro Tsujikawa <t-tujikawa@users.sourceforge.net>
Specified defaultSize as an argument for easy testing.
* src/util.cc
* src/util.h
* test/UtilTest.cc
Diffstat (limited to 'src/util.h')
| -rw-r--r-- | src/util.h | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -203,12 +203,14 @@ IntSequence parseIntRange(const std::string& src); // parameter, SIZE. For example, if "head=SIZE" is specified, pieces // in the range of first SIZE bytes of each file get higher // priority. SIZE can include K or M(1K = 1024, 1M = 1024K). +// If SIZE is omitted, SIZE=defaultSize is used. // // sample: head=512K,tail=512K void parsePrioritizePieceRange (std::vector<size_t>& result, const std::string& src, const std::vector<SharedHandle<FileEntry> >& fileEntries, - size_t pieceLength); + size_t pieceLength, + uint64_t defaultSize = 1048576 /* 1MiB */); // this function temporarily put here std::string getContentDispositionFilename(const std::string& header); |
