On Fri, 29 Mar 2002, Alex 'CAVE' Cernat wrote:

> >        SIGBUS Attempted access to a portion of  the  buffer  that
> >               does  not  correspond  to  the  file  (for example,
> >               beyond the end of  the  file,  including  the  case
> >               where another process has truncated the file).
>
> fac o paranteza fara legatura cu httpd
> nu am inteles kestia cu beyond the end of the file
> imi aduc aminte de cursul de so de la facultate unde faceam urmatoarea kestie
> ( 100 % adevarata si fara buguri )
>
> open file for writing ( create )
> write 10 bytes

ei, aci e problema, ca intre primul write si urmatorul seek cineva iti
poate intra si trunchia fisierul si atunci cand faci seek beyound the end
of file se suge.

> seek $begin + 100
> write 10 bytes ( deja sunt hat dupa sf. fisierului )
> close file
>
> kestia nu numai ca functioneaza, dar pe e2fs merge si foarte interesant, in
> sensul in care sistemul de fisiere stie sa lucreze cu fisiere cu "gauri" -
> fisierul contine pe la un moment dat blocuri care nu sunt alocate ( probabil
> $id_block = 0 ) si care sunt considerate de sistem ca blocuri intregi de
> zerouri, atunci cand cineva incearca sa citeasca din ele
>

----------------------------
Mihai RUSU

Disclaimer: Any views or opinions presented within this e-mail are solely
those of the author and do not necessarily represent those of any company,
unless otherwise specifically stated.

---
<a href="mailto:[EMAIL PROTECTED]?Subject=unsubscribe%20rlug";>unsubscribe</a>

REGULI, arhive si alte informatii: http://www.lug.ro/mlist/


Raspunde prin e-mail lui