This patch makes some of the memory manipulation performed by psql a

Neil Conway <neilc@samurai.com>

Commit: 610d33c1949005e9658863441f31083f9f3ceb9b
Author: Neil Conway <neilc@samurai.com>
Date: 2004-01-24T19:38:49Z
Releases: 8.0.0
This patch makes some of the memory manipulation performed by psql a
little more sane. Some parts of the code was using a static function
xmalloc() that did safe memory allocation (where "safe" means "bail
out on OOM"), but most of it was just invoking calloc() or malloc()
directly. Now almost everything invokes xmalloc() or xcalloc().

Files

PathChange+/−
src/bin/psql/command.c modified +6 −27
src/bin/psql/common.c modified +39 −7
src/bin/psql/common.h modified +9 −1
src/bin/psql/copy.c modified +3 −12
src/bin/psql/describe.c modified +1 −16
src/bin/psql/input.c modified +21 −25
src/bin/psql/mainloop.c modified +2 −8
src/bin/psql/print.c modified +14 −77
src/bin/psql/prompt.c modified +3 −3
src/bin/psql/startup.c modified +5 −10
src/bin/psql/stringutils.c modified +2 −4
src/bin/psql/tab-complete.c modified +10 −24
src/bin/psql/variables.c modified +10 −24