summaryrefslogtreecommitdiff
path: root/pjlib/src/pj/errno.c
diff options
context:
space:
mode:
authorNanang Izzuddin <nanang@teluu.com>2015-08-25 08:45:46 +0000
committerNanang Izzuddin <nanang@teluu.com>2015-08-25 08:45:46 +0000
commit7ffa781dc39a7274692d8db11043b3a9e92e36ce (patch)
tree77653933e1c211dbec6c125da9ec5c28f9eeaa4e /pjlib/src/pj/errno.c
parent1b41ed3f7c9361106a585c1fe43d2338ab94cacc (diff)
Re #1881: Fixed compile warnings on VS2015 about declaration hides previous declaration.
git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@5170 74dad513-b988-da41-8d7b-12977e46ad98
Diffstat (limited to 'pjlib/src/pj/errno.c')
-rw-r--r--pjlib/src/pj/errno.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/pjlib/src/pj/errno.c b/pjlib/src/pj/errno.c
index dd39e23c..8cf90f3c 100644
--- a/pjlib/src/pj/errno.c
+++ b/pjlib/src/pj/errno.c
@@ -98,11 +98,11 @@ static int pjlib_error(pj_status_t code, char *buf, pj_size_t size)
for (i=0; i<sizeof(err_str)/sizeof(err_str[0]); ++i) {
if (err_str[i].code == code) {
- pj_size_t len = strlen(err_str[i].msg);
- if (len >= size) len = size-1;
- pj_memcpy(buf, err_str[i].msg, len);
- buf[len] = '\0';
- return (int)len;
+ pj_size_t len2 = pj_ansi_strlen(err_str[i].msg);
+ if (len2 >= size) len2 = size-1;
+ pj_memcpy(buf, err_str[i].msg, len2);
+ buf[len2] = '\0';
+ return (int)len2;
}
}
#endif