forked from KolibriOS/kolibrios
t_edit can open kpack-ed files
git-svn-id: svn://kolibrios.org@9485 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
@@ -1,8 +1,13 @@
|
||||
#ifndef __KOS_LIB_H_INCLUDED_
|
||||
#define __KOS_LIB_H_INCLUDED_
|
||||
|
||||
int memcmp(const void *buf1, const void *buf2, long int count);
|
||||
void *memcpy(void *dest, const void *src, unsigned int n);
|
||||
void *memset(void *s, char c, unsigned int n);
|
||||
|
||||
unsigned int strlen(const char *str);
|
||||
char *strcpy(char *dest, const char *src);
|
||||
void *memcpy(void *dest, const void *src, unsigned int n);
|
||||
void *memset(void *s, char c, unsigned int n);
|
||||
char *strncpy(char *dest, const char *src, long int n);
|
||||
int strcmp(const char *str1, const char *str2);
|
||||
char *strchr(const char *str, int ch);
|
||||
char *strstr(const char *str1, const char *str2);
|
||||
@@ -12,4 +17,6 @@ const char *DoubleToStr(double x, unsigned short digits = 5, bool crop_0 = false
|
||||
double StrToDouble(char *str);
|
||||
long StrToInt(char *str);
|
||||
|
||||
void MessageBox(char *str);
|
||||
void MessageBox(char *str);
|
||||
|
||||
#endif
|
||||
@@ -142,6 +142,41 @@ proc @strcpy$qpcpxc uses esi edi
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
proc @strncpy$qpcpxcl uses esi edi
|
||||
cld
|
||||
mov edi,[esp+16]
|
||||
mov ecx,[esp+20]
|
||||
jecxz @f
|
||||
mov esi,edi
|
||||
xor al,al
|
||||
repnz scasb
|
||||
not ecx
|
||||
mov edi,[esp+12]
|
||||
mov edx,ecx
|
||||
mov eax,edi
|
||||
shr ecx,2
|
||||
rep movsd
|
||||
mov ecx,edx
|
||||
and ecx,3
|
||||
rep movsb
|
||||
@@:
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
proc @memcmp$qpxvt1l uses esi edi
|
||||
cld
|
||||
mov ecx,[esp+20]
|
||||
mov edi,[esp+16]
|
||||
mov esi,[esp+12]
|
||||
repe cmpsb
|
||||
movzx eax,byte[esi-1]
|
||||
movzx edx,byte[edi-1]
|
||||
sub eax,edx
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
proc @memcpy$qpvpxvui uses esi edi
|
||||
cld
|
||||
@@ -242,11 +277,11 @@ align 4
|
||||
pop esi
|
||||
inc esi
|
||||
cmp byte[edi-1],0
|
||||
jne .cycle
|
||||
jne .cycle
|
||||
|
||||
lea eax,[esi-1]
|
||||
.not_f:
|
||||
ret
|
||||
ret
|
||||
endp
|
||||
|
||||
align 4
|
||||
|
||||
Reference in New Issue
Block a user