Commit Graph

517 Commits

Author SHA1 Message Date
Phenom
c8548b2a2d Fix CppCheck in ftserver.cc
/libretroshare/src/ft/ftserver.cc:134: warning:
Cppcheck(unreadVariable): Variable 'localcachedir' is assigned a value
that is never used.
/libretroshare/src/ft/ftserver.cc:135: warning:
Cppcheck(unreadVariable): Variable 'remotecachedir' is assigned a value
that is never used.
2017-11-05 16:33:56 +01:00
Phenom
51ed0324f6 Fix CppCheck ftfilecreator.cc
/libretroshare/src/ft/ftfilecreator.cc:86: warning:
Cppcheck(unusedVariable): Unused variable: it
/libretroshare/src/ft/ftfilecreator.cc:545: warning:
Cppcheck(unreadVariable): Variable 'chunks_for_this_peer' is modified
but its new value is never used.
2017-11-05 16:33:16 +01:00
Phenom
68934499d4 Fix CppCheck in ftchunkmap.h
/libretroshare/src/ft/ftchunkmap.h:37: warning:
Cppcheck(uninitMemberVar): Member variable 'ftChunk::id' is not
initialized in the constructor.
2017-11-05 16:28:37 +01:00
csoler
2a99df4d48 added UI and parameters for two new options in shared files: max share depth and ignore duplicates 2017-09-24 17:53:06 +02:00
csoler
bc2c9d576e adding pending transfers 100 at a time instead of 1 at a time when loading 2017-09-18 22:49:51 +02:00
csoler
8189d660c4 fixed bug causing anon FT to not resume when restarting RS when the server enforces encryption 2017-09-16 22:13:15 +02:00
csoler
eff5c5d6ee added pause to file hashing 2017-09-10 22:07:36 +02:00
csoler
884b3a6220 added infrastructure to add a ignore list in shared files 2017-09-10 19:58:57 +02:00
csoler
160ab7b4f3 added missing code for remote search by hash, fixing the bug of direct sources not added 2017-09-03 23:32:48 +02:00
csoler
8d146038c2 fixed bug preventing search by hash to be called on own files 2017-09-03 22:52:31 +02:00
cyril soler
1491a051dc fixed deadlock situation in FT causing multiple bugs: lock when DLing from a file list a file that is already being downloaded, and lock when a FT module find a direct source among friends 2017-07-17 11:16:48 +02:00
Phenom
80ea4de7be Fix clang warning: unused variable 'ftserverzone'
/libretroshare/src/ft/ftserver.cc:34: warning: unused variable
'ftserverzone' [-Wunused-const-variable]
const int ftserverzone = 29539;
2017-07-16 21:16:30 +02:00
Phenom
7f1e23085d Fix clang warning: unused variable 'FT_TM_CRC_MAP_MAX_WAIT_PER_GIG', ...
/libretroshare/src/ft/fttransfermodule.cc:56: warning: unused variable
'FT_TM_CRC_MAP_MAX_WAIT_PER_GIG' [-Wunused-const-variable]
const uint32_t FT_TM_CRC_MAP_MAX_WAIT_PER_GIG = 20; /* 20 seconds per
gigabyte */
/libretroshare/src/ft/fttransfermodule.cc:65: warning: unused variable
'FT_TM_FAST_RTT' [-Wunused-const-variable]
const int32_t FT_TM_FAST_RTT    = 1.0;
/libretroshare/src/ft/fttransfermodule.cc:66: warning: unused variable
'FT_TM_STD_RTT' [-Wunused-const-variable]
const int32_t FT_TM_STD_RTT     = 5.0;
/libretroshare/src/ft/fttransfermodule.cc:67: warning: unused variable
'FT_TM_SLOW_RTT' [-Wunused-const-variable]
const int32_t FT_TM_SLOW_RTT    = 20.0;
/libretroshare/src/ft/fttransfermodule.cc:69: warning: unused variable
'FT_TM_CRC_MAP_STATE_NOCHECK' [-Wunused-const-variable]
const uint32_t FT_TM_CRC_MAP_STATE_NOCHECK      = 0 ;
/libretroshare/src/ft/fttransfermodule.cc:70: warning: unused variable
'FT_TM_CRC_MAP_STATE_DONT_HAVE' [-Wunused-const-variable]
const uint32_t FT_TM_CRC_MAP_STATE_DONT_HAVE = 1 ;
/libretroshare/src/ft/fttransfermodule.cc:71: warning: unused variable
'FT_TM_CRC_MAP_STATE_HAVE' [-Wunused-const-variable]
const uint32_t FT_TM_CRC_MAP_STATE_HAVE                 = 2 ;
2017-07-16 21:11:47 +02:00
Phenom
3a6ad822da Fix warning: this statement may fall through
/libretroshare/src/ft/ftchunkmap.cc:190: warning: this statement may
fall through [-Wimplicit-fallthrough=]
    case FileChunksInfo::CHUNK_CHECKING: _file_is_complete = false ;

/libretroshare/src/ft/ftchunkmap.cc:191: here
    case FileChunksInfo::CHUNK_DONE:   _total_downloaded +=
sizeOfChunk(i) ;
2017-07-16 20:27:09 +02:00
Phenom
54047cd7a7 Fix multi download of same file. 2017-07-06 22:38:08 +02:00
Phenom
b4071d158e Add General Direct Download setting.
Yes, No, Per User
2017-06-29 17:18:28 +02:00
csoler
e0cb0f4847 fixed previous commit 2017-05-08 23:04:04 +02:00
csoler
8a86b9ed7d added a per-friend upload slots limit in FT. Default is 0=unlimited 2017-05-08 22:00:51 +02:00
csoler
b18a186c5f fixed ftExtraList to accept e2e encrypted transfers in addition to direct transfers. This fixed the drag+drop of shared files in a distant chat 2017-05-06 18:20:48 +02:00
csoler
e401b90e02 moved rsserializer and rstypeserializer to serialiser/ 2017-04-30 16:05:37 +02:00
csoler
9c610a736d cleaned the hierarchy of serialization classes 2017-04-26 11:40:46 +02:00
csoler
0d7df568b4 moved rsconfigitems and rshistoryitems to rsitems/ 2017-04-24 22:47:08 +02:00
csoler
fcabe6359f switch RsConfigItems to new serialization 2017-04-24 18:51:51 +02:00
csoler
dc2df071a5 renamed RsSerializer into RsServiceSerializer 2017-04-24 14:14:34 +02:00
csoler
e2d9152b22 moved converted serialisation files into new directory rsitems/, leaving serialiser/ for the serialisation classes 2017-04-18 21:11:37 +02:00
csoler
121133488c fixed bug in serialization for turtle 2017-04-16 19:59:22 +02:00
csoler
636450f14d moved turtle and FT to new serialization 2017-04-15 18:46:44 +02:00
csoler
f7a1348370 made Accepted option in Transfers to send tunnel requests for both encrypted and clear tunnels 2017-01-23 19:13:50 +01:00
Phenom
674b6de381 Fix Some gcc warnings 383 to 208 lines
Left explicit #warning and deprecated.
Some lines are wrong indented and produce mal formed code.
2016-11-30 22:01:01 +01:00
mr-alice
5f69c9ea1f added an option to follow symbolic links or not, and anti-loop system during directories traversal 2016-11-24 23:42:56 +01:00
mr-alice
66c3259f9c removed debug output 2016-11-23 19:12:38 +01:00
mr-alice
fb70cb2e9e removed duplicate copy/rename file methods from ftController 2016-11-22 23:39:09 +01:00
mr-alice
47b825833a fixed the download queue, and allow queued files to start when sources get online and empty slots are present 2016-11-22 23:19:34 +01:00
csoler
5ef4e752d9 added count of total number of files and total file isze on top of shared directories 2016-11-11 20:25:11 +01:00
mr-alice
e324d7d251 removed warning in ftserver for rejected non encrypted tunnels 2016-11-03 20:31:47 +01:00
mr-alice
29b5bfe049 attempt to fixed leading tabs 2016-11-03 08:50:13 +01:00
mr-alice
1c2cfb2a03 removed debug info in ftServer 2016-11-02 21:32:14 +01:00
mr-alice
d2118c5329 supressed deadlock in ftController due to calling ftServer from ftcontroller itself 2016-11-02 20:51:42 +01:00
mr-alice
8c7c7647b0 fixed conflicts in merging upstream/master to v0.6-FTEncryption 2016-11-01 14:23:13 +01:00
mr-alice
6a3610e6cb disallow double tunnels (encrypted+clear) in Accepted mode, since it is not needed 2016-11-01 14:13:43 +01:00
mr-alice
ffdac640d8 fixed swarming with encrypted end-to-end tunnels 2016-11-01 11:57:25 +01:00
mr-alice
9d586bcfb0 made a drastic simplification pass on the ShareManager, which now only needs a single window except for selecting files using a QFileDialog 2016-10-31 16:28:26 +01:00
mr-alice
e8e054eeae addednew flag for anonymous search. Merged the two browsable flags in one single flag. 2016-10-31 14:26:01 +01:00
mr-alice
5b9ef04358 improved debug output in ftserver 2016-10-30 15:33:05 +01:00
mr-alice
def20a3f4c encrypted FT works. Fixed last bugs in ftServer 2016-10-30 15:11:22 +01:00
mr-alice
34dcb410b4 fixed a few bugs in ftServer for encrypted tunnel management 2016-10-30 11:36:00 +01:00
mr-alice
d843c1c1a6 put consts behind serial_size() and serialise() in turtle items and ft items 2016-10-29 18:18:02 +02:00
mr-alice
babc126be3 added default encryption policy variable and GUI to change it 2016-10-29 17:59:03 +02:00
mr-alice
8486346368 added new encryption/authentication format AEAD_chacha20_sha256 2016-10-26 22:05:56 +02:00
mr-alice
177752e6af fixed a few bugs in AEAD construction based on test results 2016-10-25 23:16:36 +02:00
mr-alice
0387a28e78 added methods to get files from hash(hash) in directory_storage and ftServer 2016-10-25 00:08:27 +02:00
mr-alice
2d72b88130 added code for AEAD construction 2016-10-24 15:59:34 +02:00
mr-alice
9d32406669 added ft decryption routine 2016-10-19 22:49:51 +02:00
mr-alice
3ad0a81d8f added encryption routine for FT 2016-10-19 21:30:37 +02:00
Gio
633a6cf8c2 Fixed a bunch of warnings in safe ways 2016-10-13 00:01:33 +02:00
mr-alice
9ce4b13e50 merged upstream/master 2016-09-23 19:03:54 +02:00
csoler
e6e95829bc fixed bug in estimation of next FT rate that caused downloads to stuck for a while 2016-09-22 13:44:53 +02:00
mr-alice
de104d3e34 fixed up GUI parameters in Directories. Removed HashCache duration handles since this is now automatic 2016-09-18 18:34:39 +02:00
MrAlice
ca30b0da44 fixed terrible cost of calling requestDirDetails before createIndex 2016-09-15 10:41:40 +02:00
mr-alice
93818f6088 simplified a bit the code in Flat_Model, and tried to fix the crash when sorting items 2016-09-13 21:23:27 +02:00
mr-alice
53c65fff9f removed cache transfers from the GUI 2016-09-13 18:54:00 +02:00
mr-alice
a2e34f9cc6 moved regular expression classes into a separate namespace 2016-09-13 12:05:22 +02:00
mr-alice
c1e538ff13 added interactive update of dir entries when browsing files from an online friend 2016-09-11 17:52:12 +02:00
mr-alice
ade6017f74 merged with upstream/master 2016-09-01 19:52:31 +02:00
mr-alice
ac242ce58b fixed display of own files 2016-08-16 23:44:48 +02:00
mr-alice
2668b6da1c added p3fileDatabase as a service in rsinit 2016-08-13 10:15:02 +02:00
mr-alice
538a11fd14 fixed compilation. Added missing functions, left blank 2016-07-31 15:59:58 +02:00
mr-alice
5b9fd74d85 removed most of CacheStrapper stuff from ftServer, replaced fimonitor by p3FileDatabase 2016-07-30 21:52:42 +02:00
csoler
01c0d2f0f1 finished conversion to RsNodeGroupId for file transfer and GUI 2016-07-05 23:49:43 -04:00
sehraf
cfc0e7071a libretroshare: remove unused variables 2016-06-02 14:54:07 +02:00
sehraf
f16ee97093 add static thread names 2016-06-01 16:21:55 +02:00
sehraf
b3fece25da introduce thread naming 2016-06-01 15:07:41 +02:00
csoler
d55993d1e4 removed two instances of malloc(0) captured by new rs_malloc funtion 2016-01-12 21:43:04 -05:00
csoler
d13526facd added a new method rs_malloc that checks its arguments and prints a stacktrace on error/weird call. Changed the code everywhere to use this instead of malloc. Removed some mallocs and replaced with RsTemporaryMemory 2016-01-12 21:10:11 -05:00
csoler
9c6e7dfc13 added checks after mallocs in several files 2016-01-11 23:49:00 -05:00
csoler
8a41554754 fixed some leaking memory issues in loadList() methods, and also increased consistency by not returning non empty list with deleted items inside 2015-12-30 18:20:09 -05:00
csoler
22d4893721 removed a few compilation warning that might cause compilation errors on some systems 2015-09-24 18:03:19 -04:00
thunder2
865a45f294 Fixed possible crash in ftServer::receiveTurtleData by checking return value of dynamic_cast.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@8595 b45a01b8-16f6-495d-af2f-9b41ad6348cc
2015-07-12 01:16:16 +00:00
thunder2
3abec3363d Fixed possible crash in ftServer::handleIncoming by checking return value of dynamic_cast.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@8594 b45a01b8-16f6-495d-af2f-9b41ad6348cc
2015-07-12 01:08:33 +00:00
csoler
249c827f95 improved debug info in a few places
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@8584 b45a01b8-16f6-495d-af2f-9b41ad6348cc
2015-07-09 20:55:11 +00:00
electron128
cc0f1be95d added check for return value of fseek in ftFileProvider
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@8510 b45a01b8-16f6-495d-af2f-9b41ad6348cc
2015-06-17 09:36:20 +00:00
thunder2
0ee754939e Removed some unused parameter warnings.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@8481 b45a01b8-16f6-495d-af2f-9b41ad6348cc
2015-06-15 22:41:18 +00:00
thunder2
e30e0e1f8b Fixed unitialized member on ftFileControl.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@8471 b45a01b8-16f6-495d-af2f-9b41ad6348cc
2015-06-15 18:35:09 +00:00
thunder2
fa4ce9a913 Removed unused members mStart and mEnd from ftFileCreator.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@8470 b45a01b8-16f6-495d-af2f-9b41ad6348cc
2015-06-15 18:30:02 +00:00
csoler
74d689184a removed 2 unused members from FileDetails in ftextralist
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@8443 b45a01b8-16f6-495d-af2f-9b41ad6348cc
2015-06-14 15:27:03 +00:00
csoler
e9b9dce9f5 created 2 subclasses of RsThread, one for ticking services, and one for single shot jobs. Now all threads use the same base code.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@8288 b45a01b8-16f6-495d-af2f-9b41ad6348cc
2015-05-22 20:54:38 +00:00
csoler
c9d5c7b3cb turned some std::list<PeerId> into std::set, as it automatically prevents duplicates
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@8138 b45a01b8-16f6-495d-af2f-9b41ad6348cc
2015-04-17 21:36:22 +00:00
csoler
a1b36cd530 added method in ftServer to allow retrieving data from shared/downloaded files (patch from electron, modified)
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@7999 b45a01b8-16f6-495d-af2f-9b41ad6348cc
2015-03-08 13:46:07 +00:00
csoler
d2c4c3bb09 added new flag to allow peers auto-download recommended files from trusted neighbor nodes, which give the possibility to push data to other nodes
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@7955 b45a01b8-16f6-495d-af2f-9b41ad6348cc
2015-02-18 19:07:58 +00:00
csoler
817aa793fc added non aggressive mode option to turtle router to make distant chat happy
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@7856 b45a01b8-16f6-495d-af2f-9b41ad6348cc
2015-01-22 20:25:39 +00:00
csoler
13d7866171 simplification of the chat interface to libretroshare using a single unified class for chat IDs. Used a common chat widget for all chats including broadcast. Opens the way to having plugins send/recv chat messages. Patch from Electron.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@7800 b45a01b8-16f6-495d-af2f-9b41ad6348cc
2014-12-29 21:41:05 +00:00
csoler
21fe2413cd two improvements of turtle router logic: increase of TR cache storage time to avoid too many void tunnels due to bouncing TR beyond storage period of 120 secs; prevent openning upload tunnels for files currently being downloaded before any chunk was obtained. Suggested by Jo.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@7719 b45a01b8-16f6-495d-af2f-9b41ad6348cc
2014-11-29 17:26:06 +00:00
thunder2
67215c7ffe Removed unnecessary method p3Notify::AddFeedItem.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@7674 b45a01b8-16f6-495d-af2f-9b41ad6348cc
2014-11-11 20:28:45 +00:00
csoler
d8b3a16a50 removed debug output
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@7648 b45a01b8-16f6-495d-af2f-9b41ad6348cc
2014-10-30 19:54:21 +00:00
csoler
d547cb6fdb changed post fixed operator++ into prefixed. More efficient on some systems. Patch from Phenom.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@7630 b45a01b8-16f6-495d-af2f-9b41ad6348cc
2014-10-24 22:07:26 +00:00
csoler
880efee332 removed ifdef for the different sleep methods. Now only usleep is used, on all systems. Patch from Phenom
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@7629 b45a01b8-16f6-495d-af2f-9b41ad6348cc
2014-10-24 21:31:58 +00:00
csoler
b593a918a0 optim: changed postfixed ++ into prefix++ for non trivial operators, replaced test on std::list::size() by std::list::empty() (Patch from Phenom, modified)
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@7627 b45a01b8-16f6-495d-af2f-9b41ad6348cc
2014-10-21 22:33:02 +00:00
csoler
e18c934e21 ported commit 7487 from branch 0.5.5. Seems to fix loss of config files on windows.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@7548 b45a01b8-16f6-495d-af2f-9b41ad6348cc
2014-09-20 19:54:04 +00:00
csoler
6bfe653330 small glitch fixed in std::cerr call (Patch from Vaio)
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@7512 b45a01b8-16f6-495d-af2f-9b41ad6348cc
2014-09-09 17:15:05 +00:00
csoler
0ab21fa033 removed unused ftfilemapper class
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@7511 b45a01b8-16f6-495d-af2f-9b41ad6348cc
2014-09-09 17:13:48 +00:00