Skip to content

Commit

Permalink
Bug Azure#193 fix : report failure when no source is present, indicat…
Browse files Browse the repository at this point in the history
…e message is dropped.
  • Loading branch information
darobs committed Apr 25, 2017
1 parent b96ba3a commit 601c0ac
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion modules/identitymap/src/identitymap.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) Microsoft. All rights reserved.
// Copyright (c) Microsoft. All rights reserved.
// Licensed under the MIT license. See LICENSE file in the project root for full license information.

#include <stdlib.h>
Expand Down Expand Up @@ -707,13 +707,15 @@ static bool determine_message_direction(const char * source, bool * isC2DMessage
{
/*Codes_SRS_IDMAP_17_047: [ If messageHandle property "source" is not equal to "iothub", then the message shall not be marked as a C2D message. ]*/
/*Codes_SRS_IDMAP_17_044: [ If messageHandle properties contains a "source" property that is set to "mapping", the message shall not be marked as a D2C message. ]*/
LogError("Message did not have a known source, message dropped");
result = false;
*isC2DMessage = false;
}
}
else
{
/*Codes_SRS_IDMAP_17_046: [ If messageHandle properties does not contain a "source" property, then the message shall not be marked as a C2D message. ]*/
LogError("Message did not contain a source, message dropped");
result = false;
*isC2DMessage = false;
}
Expand Down

0 comments on commit 601c0ac

Please sign in to comment.