Re: initdb in C
От | Tom Lane |
---|---|
Тема | Re: initdb in C |
Дата | |
Msg-id | 12452.1068312477@sss.pgh.pa.us обсуждение исходный текст |
Ответ на | Re: initdb in C (Bruce Momjian <pgman@candle.pha.pa.us>) |
Ответы |
Re: initdb in C
|
Список | pgsql-patches |
Bruce Momjian <pgman@candle.pha.pa.us> writes: > Recreating the directory only happens on WIN32, where rmdir doesn't > allow you to only delete files and subdirectories and not the parent > directory. Non-Win32 does rm -rf dir/*. I think we should forget about invoking rm as a subprocess at all, and just do the recursive directory walk and unlinks for ourselves. We already have code to do this for copy in copydir.c, and unlink would not be any longer. We will probably be forced into implementing database removal for ourselves rather than by 'rm' hacks anyway as soon as tablespaces come to pass; so why contort initdb's behavior for a very transient implementation savings? regards, tom lane
В списке pgsql-patches по дате отправления: