Commit Graph

40 Commits

Author SHA1 Message Date
csoler
aa471e5b2f fixed uninitialized memory read in GxsTrans 2017-07-21 10:25:20 +02:00
Phenom
8b99c80e07 Fix clang warning: 'p3GxsTrans' defined as a class here but previously
declared as a struct

/libretroshare/src/gxstrans/p3gxstrans.h:88: warning: 'p3GxsTrans'
defined as a class here but previously declared as a struct [-
Wmismatched-tags]
class p3GxsTrans : public RsGenExchange, public GxsTokenQueue, public
p3Config, public RsGxsTrans
/libretroshare/src/gxstrans/p3gxstrans.h:31: did you mean class here?
struct p3GxsTrans;
2017-07-16 21:11:10 +02:00
Phenom
c97269bed6 Fix warning: this statement may fall through
/libretroshare/src/gxstrans/p3gxstrans.cc:870: warning: this statement
may fall through [-Wimplicit-fallthrough=]
   pr.sent_ts = time(NULL) ; //pr.mailItem.meta.mPublishTs = time(NULL);
/libretroshare/src/gxstrans/p3gxstrans.cc:872: here
  case GxsTransSendStatus::PENDING_PREFERRED_GROUP:

/libretroshare/src/gxstrans/p3gxstrans.cc:883: warning: this statement
may fall through [-Wimplicit-fallthrough=]
   pr.group_id = mPreferredGroupId ; //pr.mailItem.meta.mGroupId =
mPreferredGroupId;
/libretroshare/src/gxstrans/p3gxstrans.cc:885: here
  case GxsTransSendStatus::PENDING_RECEIPT_CREATE:

/libretroshare/src/gxstrans/p3gxstrans.cc:906: warning: this statement
may fall through [-Wimplicit-fallthrough=]
   pr.presignedReceipt.msg.setBinData(&grsrz[0], grsz);
/libretroshare/src/gxstrans/p3gxstrans.cc:908: here
  case GxsTransSendStatus::PENDING_RECEIPT_SIGNATURE:     // (cyril)
This step is never actually used.

/libretroshare/src/gxstrans/p3gxstrans.cc:924: warning: this statement
may fall through [-Wimplicit-fallthrough=]
   pr.presignedReceipt.meta.setBinData(&srx[0], metaSize);
/libretroshare/src/gxstrans/p3gxstrans.cc:926: here
  case GxsTransSendStatus::PENDING_PAYLOAD_CREATE:

/libretroshare/src/gxstrans/p3gxstrans.cc:938: warning: this statement
may fall through [-Wimplicit-fallthrough=]
   memcpy(&pr.mailItem.payload[offset], &pr.mailData[0], datasize);
/libretroshare/src/gxstrans/p3gxstrans.cc:940: here
  case GxsTransSendStatus::PENDING_PAYLOAD_ENCRYPT:

/libretroshare/src/gxstrans/p3gxstrans.cc:982: warning: this statement
may fall through [-Wimplicit-fallthrough=]
   }
/libretroshare/src/gxstrans/p3gxstrans.cc:984: here
  case GxsTransSendStatus::PENDING_PUBLISH:
2017-07-16 20:47:45 +02:00
Phenom
18139489cf Fix warning: unused parameter ‘grpItem’ and unused debug variables
/libretroshare/src/gxstrans/p3gxstrans.cc:635: warning: unused parameter
‘grpItem’ [-Wunused-parameter]
         RsGxsGrpItem* grpItem, RsTlvSecurityKeySet& /*keySet*/ )

/libretroshare/src/gxstrans/p3gxstrans.cc:681: warning: unused variable
‘msgId’ [-Wunused-variable]
      const RsGxsMessageId& msgId = *vit;

/libretroshare/src/gxstrans/p3gxstrans.cc:676: warning: unused variable
‘grpId’ [-Wunused-variable]
     const RsGxsGroupId& grpId = it->first;
2017-07-16 20:46:55 +02:00
csoler
141277b131 removed debug info 2017-07-05 22:16:14 +02:00
csoler
c1e18c7fe6 fixed bug causing an infinite subscribe/unsubscribe loop in GxsTrans 2017-07-05 22:12:56 +02:00
cyril soler
f413433480 removed zeroing of preferred group causing a bug in GxsTrans 2017-07-03 11:25:12 +02:00
csoler
64e3fc97e8 fixed bug preventing correct subscribe in GxsTrans 2017-06-29 18:37:39 +02:00
csoler
700d114cf4 fixed bug causing failure of group autosubscribe in GxsTrans 2017-06-29 18:27:00 +02:00
csoler
37edcc1e37 fixed subscribe policy to GxsTrans groups as a function of last available post and group usage 2017-06-29 13:44:40 +02:00
csoler
dc605c02f1 added a last modif TS in GrpNetworkStats, that is inited from network Grp statistics, and used to provide a value for unsubscribed groups 2017-06-29 13:15:39 +02:00
csoler
533e2a8b45 added check to fix existing wrong storage time value in GxsTrans 2017-06-28 23:23:27 +02:00
csoler
f37ba83c07 moved msg keep period settings to netService and made the initialisation obei the default settings of the service 2017-06-28 23:12:33 +02:00
csoler
51c7e18a3a added last msg time in GxsTrans stats. Added mutex to protect non atomic mPreferredGroup 2017-06-27 19:56:21 +02:00
csoler
0f99647a86 fixed memory leak in GxsTrans 2017-06-23 21:58:17 +02:00
csoler
12a45294a3 added ifdef for comments on GxsTrans 2017-06-17 23:02:28 +02:00
csoler
eb4bb5be65 fixed bug in gxs trans stats counting 2017-06-17 21:42:00 +02:00
csoler
25565a7ecd merged upstream/master 2017-06-15 23:58:29 +02:00
csoler
6633b04a44 changed constants for GxsTransport anti-spam 2017-06-15 23:57:02 +02:00
csoler
26bb865d29 added code to reject messages based on existing per-user statistics 2017-06-15 19:32:31 +02:00
csoler
09ff94c9ec added new virtual method to refuse incoming msgs (similar to groups) in RsGenExchange, and used it in p3GxsTrans to refuse msgs from peers who send too much 2017-06-14 23:19:52 +02:00
csoler
1766087f71 fixed update notification and display in GxsTransStatistics 2017-06-07 23:10:59 +02:00
cyril soler
e726bd1061 attempt to fix the crash in DataStore by not calling deleteMsgs directly 2017-06-07 13:37:55 +02:00
csoler
f62028b2c1 moved metadata info to members of OutgoingRecord, so that the un-serialized meta is not lost when saved. Ensured backward compatibility when reloading old items. 2017-06-06 00:15:06 +02:00
csoler
1e652d6577 reduced number of calls to indicateConfigChanged(), and renamed mIngoingQueue into mIncomingQueue in GxsTrans 2017-06-05 22:27:54 +02:00
csoler
b7c09bd6cf added calls to indicateConfigChanged() to force saving GxsTrans outgoing records when updated 2017-06-05 21:15:42 +02:00
csoler
1967204821 restored GXS trans cleanign delay 2017-06-04 18:43:12 +02:00
csoler
831b560780 moved deletion of msgs in GxsTransport inside the service thread 2017-06-04 18:37:38 +02:00
csoler
832ba69b69 fixed up cleanup for GxsTransport 2017-05-30 21:38:59 +02:00
csoler
5410c51ab9 added cleanup thread for GxsTransport 2017-05-30 20:45:39 +02:00
csoler
0868b64436 fixed uninitialized memory read in GxsTrans msg Id 2017-05-28 22:49:07 +02:00
csoler
eea63ac217 minor code cleaning in p3GxsTrans (struct->class for consistency, sendMail->sendData), added popularity+subscribed status display in statistics 2017-05-27 22:19:52 +02:00
csoler
7c439983de Merge pull request #842 from csoler/v0.6-GxsTransport
V0.6 gxs transport
2017-05-26 22:04:33 +02:00
csoler
a3096f26a5 added data hash to GxsTrans display 2017-05-26 20:28:44 +02:00
csoler
a136fb6fda added display of ongoing record status for GxsTrans. Unfinished. 2017-05-22 23:54:55 +02:00
csoler
fbeb6ff98d added infrastructure for gathering statistics about GxsTransport. Unfinished. 2017-05-21 15:57:10 +02:00
Gioacchino Mazzurco
10ec52718d Fix GxsTrans related serialization regressions 2017-05-15 19:13:29 +02:00
Gioacchino Mazzurco
ea8f800003 Port GxsTrans to new serialization system
RsItem added some comment and more verbose error reporting
RsTypeSerializer added support for RsItem derived classes as members
  added utility macros for better readability of the code and easier
  handling of RsItem derived members
  RS_REGISTER_SERIAL_MEMBER(I)
  RS_REGISTER_SERIAL_MEMBER_TYPED(I, T)
  RS_REGISTER_ITEM_TYPE(T)

RsNxsMsg::serial_process use new macros for better readability and to
 have an exemple of usage with RsTlvItem derived class
Fix undefined reference to RsNxsMsg::print
2017-05-08 00:19:11 +02:00
Gioacchino Mazzurco
5c434fb107 Fix typos reported by Jums 2017-03-03 12:21:43 +01:00
Gioacchino Mazzurco
da459c884e Renamed GxsMails to GxsTrans
GxsTrans is a generic transport service, use more generic name trans
 instead of mail to avoid confusion
Renamed size(...) to seria_size(...) for costistence whit the codebase
Moved GxsTrans and related things to gxstrans directory
Removed outdated and now uncompatible gxsmail test service
Avoid expose internal items in public interface methods
2017-03-02 02:37:53 +01:00