diff options
| author | unknown <pesco@khjk.org> | 2013-08-03 15:36:53 +0200 | 
|---|---|---|
| committer | unknown <pesco@khjk.org> | 2013-08-03 15:36:53 +0200 | 
| commit | 51f937efd8653a3dc79ba1dbdb93fc2c69c78504 (patch) | |
| tree | 6eb43063c22db824b4b34eaa7f217aa30ddfbc8d /otr.c | |
| parent | e4752a6162d27e7292df912ab3bbf71f214e6cce (diff) | |
log OTR heartbeats if set verbose
Diffstat (limited to 'otr.c')
| -rw-r--r-- | otr.c | 14 | 
1 files changed, 13 insertions, 1 deletions
| @@ -879,6 +879,18 @@ void op_handle_msg_event(void *opdata, OtrlMessageEvent ev, ConnContext *ctx,  		display_otr_message(opdata, ctx,  			"malformed OTR message received");  		break; +	case OTRL_MSGEVENT_LOG_HEARTBEAT_RCVD: +		if(global.conf->verbose) { +			log_otr_message(opdata, "%s/%s: heartbeat received", +				ctx->accountname, ctx->protocol); +		} +		break; +	case OTRL_MSGEVENT_LOG_HEARTBEAT_SENT: +		if(global.conf->verbose) { +			log_otr_message(opdata, "%s/%s: heartbeat sent", +				ctx->accountname, ctx->protocol); +		} +		break;  	case OTRL_MSGEVENT_RCVDMSG_GENERAL_ERR:  		display_otr_message(opdata, ctx,  			"OTR error message received: %s", message); @@ -896,7 +908,7 @@ void op_handle_msg_event(void *opdata, OtrlMessageEvent ev, ConnContext *ctx,  			"OTR message for a different instance received");  		break;  	default: -		/* ignore  XXX log? */ +		/* shouldn't happen */  		break;  	}  } | 
