mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 07:48:11 +00:00
Kernel: Don't disable interrupts to access the system hostname.
This commit is contained in:
parent
458706c4cf
commit
2e663eda36
3 changed files with 18 additions and 16 deletions
|
@ -40,6 +40,16 @@ void strcpy(char* dest, const char *src)
|
|||
while ((*dest++ = *src++) != '\0');
|
||||
}
|
||||
|
||||
char* strncpy(char* dest, const char* src, size_t n)
|
||||
{
|
||||
size_t i;
|
||||
for (i = 0; i < n && src[i] != '\0'; ++i)
|
||||
dest[i] = src[i];
|
||||
for ( ; i < n; ++i)
|
||||
dest[i] = '\0';
|
||||
return dest;
|
||||
}
|
||||
|
||||
void* memset(void* dest_ptr, byte c, dword n)
|
||||
{
|
||||
dword dest = (dword)dest_ptr;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue