From 70da61f5d13cc45569e391d7db6182375c8a484a Mon Sep 17 00:00:00 2001 From: Jonas 'Sortie' Termansen Date: Sat, 22 Sep 2012 22:44:50 +0200 Subject: [PATCH] Replace Maxsi::String::Copy with strcpy. --- sortix/directory.cpp | 4 ++-- sortix/fs/videofs.cpp | 2 +- sortix/kernelinfo.cpp | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/sortix/directory.cpp b/sortix/directory.cpp index 64679e70..22f67536 100644 --- a/sortix/directory.cpp +++ b/sortix/directory.cpp @@ -124,7 +124,7 @@ namespace Sortix if ( !wd ) { wd = "/"; } size_t wdsize = strlen(wd) + 1; if ( size < wdsize ) { errno = ERANGE; return NULL; } - String::Copy(buf, wd); + strcpy(buf, wd); return buf; } @@ -151,7 +151,7 @@ namespace Sortix // interpretation from that point. size_t offset; if ( *rel == '/' ) { result[0] = '/'; offset = 1; rel++; } - else { String::Copy(result, wd); offset = wdlen; } + else { strcpy(result, wd); offset = wdlen; } // Make sure the working directory ends with a slash. if ( result[offset-1] != '/' ) { result[offset++] = '/'; } diff --git a/sortix/fs/videofs.cpp b/sortix/fs/videofs.cpp index c3426c30..efd027a7 100644 --- a/sortix/fs/videofs.cpp +++ b/sortix/fs/videofs.cpp @@ -173,7 +173,7 @@ Device* MakeModes(int flags, mode_t /*mode*/) if ( !modesstr ) { goto out; } for ( size_t i = 0; i < nummodes; i++ ) { - String::Copy(modesstr + sofar, modes[i]); + strcpy(modesstr + sofar, modes[i]); sofar += strlen(modes[i]); modesstr[sofar++] = '\n'; } diff --git a/sortix/kernelinfo.cpp b/sortix/kernelinfo.cpp index ec7099dc..6760cf47 100644 --- a/sortix/kernelinfo.cpp +++ b/sortix/kernelinfo.cpp @@ -56,7 +56,7 @@ ssize_t SysKernelInfo(const char* req, char* resp, size_t resplen) errno = ERANGE; return (ssize_t) stringlen; } - String::Copy(resp, str); + strcpy(resp, str); return 0; }