Skip to content

Commit

Permalink
Merge pull request #64 from suvi-123/err_string_map
Browse files Browse the repository at this point in the history
wdmp error to string mapping
  • Loading branch information
shilpa24balaji committed Feb 15, 2023
2 parents 9a4b0e0 + 838c52b commit f9f687b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/wdmp-c.h
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,8 @@ typedef enum
WDMP_ERR_INVALID_RADIO_INDEX,
WDMP_ERR_ATOMIC_GET_SET_FAILED,
WDMP_ERR_METHOD_NOT_SUPPORTED,
WDMP_ERR_SESSION_IN_PROGRESS
WDMP_ERR_SESSION_IN_PROGRESS,
WDMP_ERR_MAX_REQUEST
} WDMP_STATUS;

typedef struct
Expand Down
4 changes: 4 additions & 0 deletions src/wdmp_internal.c
Original file line number Diff line number Diff line change
Expand Up @@ -804,6 +804,10 @@ void wdmp_form_table_response(res_struct *resObj, cJSON *response)
{
strcpy(result,"Previous request is in progress");
}
else if (status == WDMP_ERR_MAX_REQUEST)
{
strcpy(result,"Max SET request limit reached");
}
else
{
strcpy(result,"Unknown Error");
Expand Down

0 comments on commit f9f687b

Please sign in to comment.