Re: pg_dump and large files - is this a problem?

Поиск
Список
Период
Сортировка
От Bruce Momjian
Тема Re: pg_dump and large files - is this a problem?
Дата
Msg-id 200210240203.g9O23ID27123@candle.pha.pa.us
обсуждение исходный текст
Ответ на Re: pg_dump and large files - is this a problem?  (Philip Warner <pjw@rhyme.com.au>)
Ответы Re: pg_dump and large files - is this a problem?  (Philip Warner <pjw@rhyme.com.au>)
Список pgsql-hackers
Philip Warner wrote:
> At 09:45 PM 23/10/2002 -0400, Bruce Momjian wrote:
> >We have to write another function because fsetpos doesn't do SEEK_CUR so
> >you have to implement it with more complex code.  It isn't a drop in
> >place thing.
> 
> The only code that uses SEEK_CUR is the code to check if seek is available 
> - I am ver happy to change that to SEEK_SET - I can't even recall why I 
> used SEEK_CUR. The code that does the real seeks uses SEEK_SET.

There are other problems.  fgetpos() expects a pointer to an fpos_t,
while ftello just returns off_t, so you need a local variable in the
function to pass to fgetpos() and they return that from the function.

It is much cleaner to just duplicate the entire API so you don't have
any limitations or failure cases.

--  Bruce Momjian                        |  http://candle.pha.pa.us pgman@candle.pha.pa.us               |  (610)
359-1001+  If your life is a hard drive,     |  13 Roberts Road +  Christ can be your backup.        |  Newtown Square,
Pennsylvania19073
 


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

Предыдущее
От: Philip Warner
Дата:
Сообщение: Re: pg_dump and large files - is this a problem?
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: pg_dump and large files - is this a problem?