From: Wootak Jung Date: Mon, 13 Feb 2017 00:57:31 +0000 (+0900) Subject: Fix memory leak issue X-Git-Tag: accepted/tizen/common/20170227.043025^0 X-Git-Url: http://review.tizen.org/git/?p=platform%2Fcore%2Ftelephony%2Ftel-plugin-indicator.git;a=commitdiff_plain;h=e48e9900cc1ca3e761b7d21a554a6e327d274fa1 Fix memory leak issue Change-Id: I43aee94332ec960ef0da6c08c5eb7a7eb1ad9131 --- diff --git a/packaging/tel-plugin-indicator.spec b/packaging/tel-plugin-indicator.spec index 7fa55b7..1cec727 100644 --- a/packaging/tel-plugin-indicator.spec +++ b/packaging/tel-plugin-indicator.spec @@ -1,6 +1,6 @@ %define major 0 %define minor 1 -%define patchlevel 71 +%define patchlevel 72 Name: tel-plugin-indicator Version: %{major}.%{minor}.%{patchlevel} diff --git a/src/s_indi_main.c b/src/s_indi_main.c index 37a5c5a..d4113ac 100644 --- a/src/s_indi_main.c +++ b/src/s_indi_main.c @@ -391,8 +391,8 @@ gboolean __s_indi_update_callback(__s_indi_cb_user_data *data) } } - rx_changes_total = rx_curr_total - rx_prev_total; - tx_changes_total = tx_curr_total - tx_prev_total; + rx_changes_total = ((rx_curr_total > rx_prev_total) ? (rx_curr_total - rx_prev_total) : S_INDI_ZERO); + tx_changes_total = ((tx_curr_total > tx_prev_total) ? (tx_curr_total - tx_prev_total) : S_INDI_ZERO); if (rx_changes_total) cp_state |= S_INDI_TRANSFER_RX;