Skip to content

Commit

Permalink
Disable debug logs
Browse files Browse the repository at this point in the history
  • Loading branch information
sadhyama committed Sep 27, 2023
1 parent 3cfdcb7 commit ebcaea0
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions src/webcfg_db.c
Original file line number Diff line number Diff line change
Expand Up @@ -704,7 +704,7 @@ WEBCFG_STATUS deleteFromTmpList(char* doc_name, webconfig_tmp_data_t **next_node
WebcfgError("Invalid value for doc\n");
return WEBCFG_FAILURE;
}
WebcfgInfo("doc to be deleted: %s\n", doc_name);
WebcfgDebug("doc to be deleted: %s\n", doc_name);

prev_node = NULL;
pthread_mutex_lock (&webconfig_tmp_data_mut);
Expand All @@ -714,30 +714,30 @@ WEBCFG_STATUS deleteFromTmpList(char* doc_name, webconfig_tmp_data_t **next_node
{
if(strcmp(curr_node->name, doc_name) == 0)
{
WebcfgInfo("Found the node to delete\n");
WebcfgDebug("Found the node to delete\n");
if( NULL == prev_node )
{
WebcfgInfo("need to delete first doc\n");
WebcfgDebug("need to delete first doc\n");
g_head = curr_node->next;
}
else
{
WebcfgInfo("Traversing to find node\n");
WebcfgDebug("Traversing to find node\n");
prev_node->next = curr_node->next;
*next_node = curr_node->next;

}

WebcfgInfo("Deleting the node entries\n");
WebcfgDebug("Deleting the node entries\n");
WEBCFG_FREE( curr_node->name );
WEBCFG_FREE( curr_node->status );
WEBCFG_FREE( curr_node->error_details );
WEBCFG_FREE( curr_node->cloud_trans_id);
WEBCFG_FREE( curr_node );
curr_node = NULL;
WebcfgInfo("Deleted successfully and returning..\n");
WebcfgDebug("Deleted successfully and returning..\n");
numOfMpDocs =numOfMpDocs - 1;
WebcfgInfo("numOfMpDocs after delete is %d\n", numOfMpDocs);
WebcfgDebug("numOfMpDocs after delete is %d\n", numOfMpDocs);
pthread_mutex_unlock (&webconfig_tmp_data_mut);
return WEBCFG_SUCCESS;
}
Expand Down Expand Up @@ -797,12 +797,12 @@ void release_success_docs_tmplist()
webconfig_tmp_data_t *temp = NULL, *next_node = NULL;
temp = get_global_tmp_node();

WebcfgInfo("Inside release_success_docs_list()\n");
WebcfgDebug("Inside release_success_docs_list()\n");
while(temp != NULL)
{
if((temp->status != NULL) && (strcmp(temp->status, "success") ==0))
{
WebcfgInfo("Delete node--> temp->name %s temp->version %lu temp->status %s temp->isSupplementarySync %d temp->error_details %s temp->error_code %lu temp->trans_id %lu temp->retry_count %d temp->cloud_trans_id %s\n",temp->name, (long)temp->version, temp->status, temp->isSupplementarySync, temp->error_details, (long)temp->error_code, (long)temp->trans_id, temp->retry_count, temp->cloud_trans_id);
WebcfgDebug("Delete node--> temp->name %s temp->version %lu temp->status %s temp->isSupplementarySync %d temp->error_details %s temp->error_code %lu temp->trans_id %lu temp->retry_count %d temp->cloud_trans_id %s\n",temp->name, (long)temp->version, temp->status, temp->isSupplementarySync, temp->error_details, (long)temp->error_code, (long)temp->trans_id, temp->retry_count, temp->cloud_trans_id);
deleteFromTmpList(temp->name,&next_node);
temp = next_node;
continue;
Expand Down

0 comments on commit ebcaea0

Please sign in to comment.