[BACKPORT] res_create_query: avoid single-byte buffer overwrite

... when the name ends with an escaped dot.

CVE-2016-5180
https://c-ares.haxx.se/adv_20160929.html

Bug: b/32205736
Test: Compile test app from aospg/300423

Change-Id: Ice232d136a81aaa9b29f58b2aea59e8c6467af28
1 file changed