Re: why was the VAR 'optind' never changed in initdb?

Поиск
Список
Период
Сортировка
От Andrew Dunstan
Тема Re: why was the VAR 'optind' never changed in initdb?
Дата
Msg-id 4F82DAE8.2000300@dunslane.net
обсуждение исходный текст
Ответ на why was the VAR 'optind' never changed in initdb?  (Clover White <mywhiteclover@gmail.com>)
Ответы Re: why was the VAR 'optind' never changed in initdb?  (Clover White <mywhiteclover@gmail.com>)
Список pgsql-hackers

On 04/09/2012 07:38 AM, Clover White wrote:
> Hi,
>   I'm debugging initdb using gdb.
>   I found that I could not step in the function getopt_long in line 
> 2572 in initdb.c.
>   I also found that the value of VAR optind never be changed. VAR 
> optind is always equal to 1 but how could optind be larger than the 
> value of argc(the value of argc is 6) in line 2648 and 2654.
>
> I was so confused. Could someone give me some help? Thank you~
>
>

Why do you expect it to be? Perhaps if you tell us what problem you're 
actually trying to solve we can help you better.

cheers

andrew


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Clover White
Дата:
Сообщение: why was the VAR 'optind' never changed in initdb?
Следующее
От: Euler Taveira
Дата:
Сообщение: Re: [patch] for "psql : Allow processing of multiple -f (file) options "