Merged revisions 327046 via svnmerge from
authorRussell Bryant <russell@russellbryant.com>
Fri, 8 Jul 2011 16:00:46 +0000 (16:00 +0000)
committerRussell Bryant <russell@russellbryant.com>
Fri, 8 Jul 2011 16:00:46 +0000 (16:00 +0000)
https://origsvn.digium.com/svn/asterisk/branches/1.8

........
  r327046 | russell | 2011-07-08 11:00:05 -0500 (Fri, 08 Jul 2011) | 2 lines

  Fix an error and add more log message info to help see why this fails on FreeBSD.
........

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@327047 65c4cc65-6c06-0410-ace0-fbb531ad65f3

tests/test_netsock2.c

index 3bbf257..f759ed2 100644 (file)
@@ -101,7 +101,9 @@ AST_TEST_DEFINE(parsing)
                        tmp = ast_sockaddr_stringify(&addr);
                        ast_sockaddr_parse(&tmp_addr, tmp, 0);
                        if (ast_sockaddr_cmp_addr(&addr, &tmp_addr)) {
-                               ast_test_status_update(test, "Re-parsed stringification did not match: '%s' vs '%s'\n", ast_sockaddr_stringify(&addr), ast_sockaddr_stringify(&tmp_addr));
+                               char buf[64];
+                               ast_copy_string(buf, ast_sockaddr_stringify(&addr), sizeof(buf));
+                               ast_test_status_update(test, "Re-parsed stringification of '%s' did not match: '%s' vs '%s'\n", test_vals[x].address, buf, ast_sockaddr_stringify(&tmp_addr));
                                res = AST_TEST_FAIL;
                        }
                }