Re: pg_ctl
| От | Joshua D. Drake |
|---|---|
| Тема | Re: pg_ctl |
| Дата | |
| Msg-id | 3FCBD4BE.3060301@commandprompt.com обсуждение исходный текст |
| Ответ на | pg_ctl (Andrew Dunstan <andrew@dunslane.net>) |
| Список | pgsql-hackers-win32 |
Communicated. Andrew Dunstan wrote: > > I briefly reviewed the alpha version of this that Joshua posted a URL > to (after converting all the c++ style comments and running through > pgindent so I could read it). > > I endorse Neil's and Bruce's comments. In addition, I noticed these > things: > > . on Win32 a start op is guaranteed to hang unless I'm misreading the > code, as it is not backgrounded. Calling system() won't work here - I > think we'll have to call CreateProcess() on Win32. > . what about devnull processing on Win32? > . multi-line literals are apparently illegal (see recent hackers > thread?) and rejected by some compilers - use the fact that the > compiler will concatentate adjacent string literals. > . there is a lot of incorrect code that tries to do things that are > already done correctly and portably in initdb.c - e.g. finding the > postmaster executable. > . calling fopen() to check existence of a file is, er, suboptimal. Use > stat(). > . no error checking on malloc() calls > . calling free() on these tiny strings is quite unnecessary - the > program should use minimal memory and have a very short life span. > It's just useless clutter IMNSHO. > > This isn't an exhaustive list. > > I suspect this work is actually a bit premature, and would best be > done after we have a working Win32 postmaster. After all, you can > happily run postgres without ever calling pg_ctl - it's a convenience > rather than an absolute necessity (unlike initdb). On Windows, > production users probably wouldn't use it at all - they would use the > service manager, I should think. > > cheers > > andrew > > > > > > ---------------------------(end of broadcast)--------------------------- > TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org -- Command Prompt, Inc., home of Mammoth PostgreSQL - S/ODBC and S/JDBC Postgresql support, programming shared hosting and dedicated hosting. +1-503-667-4564 - jd@commandprompt.com - http://www.commandprompt.com Mammoth PostgreSQL Replicator. Integrated Replication for PostgreSQL
В списке pgsql-hackers-win32 по дате отправления: