celix-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] [celix] pnoltes commented on a change in pull request #156: Added protocol service API and wire protocol implementation to be use…
Date Thu, 05 Mar 2020 09:39:04 GMT
pnoltes commented on a change in pull request #156: Added protocol service API and wire protocol
implementation to be use…
URL: https://github.com/apache/celix/pull/156#discussion_r388175963
 
 

 ##########
 File path: bundles/pubsub/examples/pubsub/subscriber/private/src/pubsub_subscriber.c
 ##########
 @@ -53,9 +55,19 @@ void subscriber_destroy(pubsub_receiver_t *subscriber) {
     free(subscriber);
 }
 
-int pubsub_subscriber_recv(void* handle, const char* msgType, unsigned int msgTypeId, void*
msg, bool* release) {
+int pubsub_subscriber_recv(void* handle, const char* msgType, unsigned int msgTypeId, void*
msg, const celix_properties_t *metadata, bool* release) {
     location_t place = (location_t)msg;
     printf("Recv (%s): [%f, %f] (%s, %s, %s, len data %li)\n", msgType, place->position.lat,
place->position.lon, place->name, place->description, place->extra, (long)(strlen(place->data)
+ 1));
 
+    if (metadata == NULL || celix_properties_size(metadata) == 0) {
+        printf("No metadata\n");
 
 Review comment:
   remove printf

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

Mime
View raw message