aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator/beam/beam_bp.c
diff options
context:
space:
mode:
authorBjörn-Egil Dahlberg <[email protected]>2011-11-07 17:24:08 +0100
committerBjörn-Egil Dahlberg <[email protected]>2011-11-07 17:24:08 +0100
commit766a0a84f0b9e4b9341fb06364bf5430574588a6 (patch)
tree4e0b881a5806f6a75661b20d56a77e780bf24cd6 /erts/emulator/beam/beam_bp.c
parentdd2f23d718f079afb12b8d0b9d288428fb0ad49d (diff)
parent4e73d4bee3fd7744ebaf9f672a0ab5bc6528301f (diff)
downloadotp-766a0a84f0b9e4b9341fb06364bf5430574588a6.tar.gz
otp-766a0a84f0b9e4b9341fb06364bf5430574588a6.tar.bz2
otp-766a0a84f0b9e4b9341fb06364bf5430574588a6.zip
Merge branch 'egil/fix-compiler-warnings'
* egil/fix-compiler-warnings: erts: Remove unused variable in enif_make_binary erts: Remove debug variable in list_to_binary erts: Remove cp on exiting and trapping processes erts: Remove debug variables in erl_db erts: Remove dead code in efile_drv erts: Remove lock_check debug variables erts: Remove unused variable in ttsl_drv erts: "initialized" is only used with CHLDWTHR erts: remove debug variables in beam_bp
Diffstat (limited to 'erts/emulator/beam/beam_bp.c')
-rw-r--r--erts/emulator/beam/beam_bp.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/erts/emulator/beam/beam_bp.c b/erts/emulator/beam/beam_bp.c
index 773baad01f..c90795c343 100644
--- a/erts/emulator/beam/beam_bp.c
+++ b/erts/emulator/beam/beam_bp.c
@@ -612,9 +612,13 @@ static void bp_hash_delete(bp_time_hash_t *hash) {
static void bp_time_diff(bp_data_time_item_t *item, /* out */
process_breakpoint_time_t *pbt, /* in */
Uint ms, Uint s, Uint us) {
- int dms,ds,dus;
+ int ds,dus;
+#ifdef DEBUG
+ int dms;
+
dms = ms - pbt->ms;
+#endif
ds = s - pbt->s;
dus = us - pbt->us;
@@ -622,7 +626,9 @@ static void bp_time_diff(bp_data_time_item_t *item, /* out */
* this is ok.
*/
+#ifdef DEBUG
ASSERT(dms >= 0 || ds >= 0 || dus >= 0);
+#endif
if (dus < 0) {
dus += 1000000;