diff options
author | bbryant <bbryant@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-07-08 16:40:28 +0000 |
---|---|---|
committer | bbryant <bbryant@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-07-08 16:40:28 +0000 |
commit | 0110f8c87a0481038e3673640c387417fb339b4c (patch) | |
tree | df03af827ea95734e2906e4737660d983e3e0b01 /main/rtp.c | |
parent | cdea52a3def39e3b06cb2ef6f0ca88a4c5f710a8 (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: http://svn.digium.com/svn/asterisk/trunk@129045 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'main/rtp.c')
-rw-r--r-- | main/rtp.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/main/rtp.c b/main/rtp.c index c0c2bf17f..1370e12d2 100644 --- a/main/rtp.c +++ b/main/rtp.c @@ -2205,7 +2205,7 @@ int ast_rtp_set_rtpmap_type(struct ast_rtp *rtp, int pt, rtp_bridge_lock(rtp); - for (i = 0; i < sizeof(mimeTypes)/sizeof(mimeTypes[0]); ++i) { + for (i = 0; i < ARRAY_LEN(mimeTypes); ++i) { if (strcasecmp(mimeSubtype, mimeTypes[i].subtype) == 0 && strcasecmp(mimeType, mimeTypes[i].type) == 0) { found = 1; @@ -2312,7 +2312,7 @@ const char *ast_rtp_lookup_mime_subtype(const int isAstFormat, const int code, { unsigned int i; - for (i = 0; i < sizeof(mimeTypes)/sizeof(mimeTypes[0]); ++i) { + for (i = 0; i < ARRAY_LEN(mimeTypes); ++i) { if ((mimeTypes[i].payloadType.code == code) && (mimeTypes[i].payloadType.isAstFormat == isAstFormat)) { if (isAstFormat && (code == AST_FORMAT_G726_AAL2) && |