Magnus Hagander mha
Sun Jul 17 15:46:11 PDT 2005
Hi!

The function get_sharepath() in slonik (used only on win32) is badly
broken as it is now. For one thing, it loops on an unsigned int var with
a condition of ">=0", which is always true. Which results in it happily
overwriting argv[] (and probably other such things!) makeing it
impossible to run a simple command like "slonik foo" (because once it
tries to open the file, argv[1] is now NULL).

Attached patch cleans that up. Still uses the same logic (assuming I
read the original logic correctly). It's a bit simplistic, but I think
it will be enough for most cases.

//Magnus
-------------- next part --------------
A non-text attachment was scrubbed...
Name: slonik_sharepath.patch
Type: application/octet-stream
Size: 2513 bytes
Desc: slonik_sharepath.patch
Url : http://gborg.postgresql.org/pipermail/slony1-general/attachments/20050717/f1c8c160/slonik_sharepath.obj


More information about the Slony1-general mailing list