On Mon, 03 Jul 2006 14:50:11 +0200, "¬a\\/b" <al@[EMAIL PROTECTED]
> wrote:
>On Mon, 03 Jul 2006 09:23:55 +0200, "¬a\\/b" <al@[EMAIL PROTECTED]
> wrote:
>>.c2: [i+@[EMAIL PROTECTED]
r=@[EMAIL PROTECTED]
c=s; ReadFile(r, a, j, c, 0);
> ^^^^^
>this should be r=[i+@[EMAIL PROTECTED]
>
>i wrote a function for to write in the files
>if in b there is the int_file_descrittor, and any function return its
>value in "a" in your opinione something of this kind can work in a
>windows OS?
>
>int __stdcall write_m(int fd, char* base, int len)
>{int a, b, k, mm, *s=&mm, b=fd;
> a=GetFileType(b); if(a==FILE_TYPE_DISK) {k=-1; goto .c2;}
if(a!=
> a=SetFilePointer(b, 0, 0, FILE_END);
> if(a==-1) {CF=1; a=0; goto .cf;}
> k=a; a+=len; a=LockFile(b, k, 0, a, 0);
> if(a==0) {CF=1; goto .cf;}
>.c2: c=base; r=len; a=s; a=WriteFile(b, c, r, a, 0);
> if(k==-1) goto .c3;
> a=k; a+=len; a=UnlockFile(b, k, 0, a, 0);
> if(a==0) {CF=1; a=*s; goto .cf;}
>.c3: a=*s; if(a!=len) {CF=1; goto .cf;}
> CF=0;
>.cf: return a;
>}


|