]> granicus.if.org Git - postgresql/commit
Remove a couple of useless pstrdup() calls.
authorTom Lane <tgl@sss.pgh.pa.us>
Thu, 10 Mar 2016 04:29:05 +0000 (23:29 -0500)
committerTom Lane <tgl@sss.pgh.pa.us>
Thu, 10 Mar 2016 04:29:05 +0000 (23:29 -0500)
commitcc402116ca156babcd3ef941317f462a96277e3a
tree083bf516092f2f04dabafc19ca0827b3caee83f9
parent1d4a0ab19a7e45aa8b94d7f720d1d9cefb81ec40
Remove a couple of useless pstrdup() calls.

There's no point in pstrdup'ing the result of TextDatumGetCString,
since that's necessarily already a freshly-palloc'd C string.

These particular calls are unlikely to be of any consequence
performance-wise, but still they're a bad precedent that can confuse
future patch authors.

Noted by Chapman Flack.
src/backend/foreign/foreign.c