[sr-dev] git:5.5:10cfb3ea: db_perlvdb: removed unnecessary condition

Daniel-Constantin Mierla miconda at gmail.com
Mon Feb 14 15:03:44 CET 2022


Module: kamailio
Branch: 5.5
Commit: 10cfb3ea0e80cfbaa5745093d471a58997a633ff
URL: https://github.com/kamailio/kamailio/commit/10cfb3ea0e80cfbaa5745093d471a58997a633ff

Author: Daniel-Constantin Mierla <miconda at gmail.com>
Committer: Daniel-Constantin Mierla <miconda at gmail.com>
Date: 2022-02-14T13:02:32+01:00

db_perlvdb: removed unnecessary condition

(cherry picked from commit d3daed0a617024fde1efabbcdab27dc4c5c140c8)

---

Modified: src/modules/db_perlvdb/perlvdb_conv.c

---

Diff:  https://github.com/kamailio/kamailio/commit/10cfb3ea0e80cfbaa5745093d471a58997a633ff.diff
Patch: https://github.com/kamailio/kamailio/commit/10cfb3ea0e80cfbaa5745093d471a58997a633ff.patch

---

diff --git a/src/modules/db_perlvdb/perlvdb_conv.c b/src/modules/db_perlvdb/perlvdb_conv.c
index f263774658..fcf7b024a5 100644
--- a/src/modules/db_perlvdb/perlvdb_conv.c
+++ b/src/modules/db_perlvdb/perlvdb_conv.c
@@ -57,9 +57,8 @@ AV *conds2perlarray(const db_key_t* keys, const db_op_t* ops, const db_val_t* va
 
 	for (i = 0; i < n; i++) {
 		if (ops) {
-			if (ops + i)
-				if (*(ops + i))
-					element = cond2perlcond(*(keys + i),
+			if (*(ops + i))
+				element = cond2perlcond(*(keys + i),
 							*(ops + i), vals + i);
 		} else {
 /* OP_EQ is defined in Kamailio _and_ perl. Includes collide :( */




More information about the sr-dev mailing list