stringfields: Fix bug in ast_string_fields_copy.
authorCorey Farrell <git@cfware.com>
Wed, 19 Nov 2014 19:32:23 +0000 (19:32 +0000)
committerCorey Farrell <git@cfware.com>
Wed, 19 Nov 2014 19:32:23 +0000 (19:32 +0000)
commit57c6f89bf082fafb64800ce49b4da74a9c2d8d9d
tree0e7afee99775e0889582fe0e1afec24bac81ac0f
parenta7c9f4c668c3b5d42f98d06ab0c20d81bd5fd25e
stringfields: Fix bug in ast_string_fields_copy.

ast_string_fields_copy relies on the fact that
__ast_string_field_release_active never previously
zeroed pool->used, so keeping the existing pointer
was "ok".  Now that existing pools can be reset to
'empty', it is important to set each field to
__ast_string_field_empty after releasing the memory.

ASTERISK-24535 #close
Reported by: Corey Farrell
Review: https://reviewboard.asterisk.org/r/4186/
........

Merged revisions 428272 from http://svn.asterisk.org/svn/asterisk/branches/12
........

Merged revisions 428273 from http://svn.asterisk.org/svn/asterisk/branches/13

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