diff options
author | Brett Bryant <bbryant@digium.com> | 2008-07-08 16:40:28 +0000 |
---|---|---|
committer | Brett Bryant <bbryant@digium.com> | 2008-07-08 16:40:28 +0000 |
commit | d1854057559b8893eee71c7b52356d80a24eb72b (patch) | |
tree | df03af827ea95734e2906e4737660d983e3e0b01 /pbx | |
parent | 2ed6cea5515860b2b062a70c18b3118266716abd (diff) |
Janitor project to convert sizeof to ARRAY_LEN macro.
(closes issue #13002)
Reported by: caio1982
Patches:
janitor_arraylen5.diff uploaded by caio1982 (license 22)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@129045 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'pbx')
-rw-r--r-- | pbx/dundi-parser.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/pbx/dundi-parser.c b/pbx/dundi-parser.c index aca902a3a..b37c6905f 100644 --- a/pbx/dundi-parser.c +++ b/pbx/dundi-parser.c @@ -71,7 +71,7 @@ int dundi_str_short_to_eid(dundi_eid *eid, const char *s) if (sscanf(s, "%2x%2x%2x%2x%2x%2x", &eid_int[0], &eid_int[1], &eid_int[2], &eid_int[3], &eid_int[4], &eid_int[5]) != 6) return -1; - for (x=0;x<6;x++) + for (x = 0; x < 6; x++) eid->eid[x] = eid_int[x]; return 0; } @@ -79,7 +79,7 @@ int dundi_str_short_to_eid(dundi_eid *eid, const char *s) int dundi_eid_zero(dundi_eid *eid) { int x; - for (x=0;x<sizeof(eid->eid) / sizeof(eid->eid[0]);x++) + for (x = 0; x < ARRAY_LEN(eid->eid); x++) if (eid->eid[x]) return 0; return 1; } |