mirror of https://github.com/stella-emu/stella.git
fixed two warnings
This commit is contained in:
parent
2c8a567810
commit
492596011a
|
@ -256,7 +256,7 @@ ZipHandler::zip_error ZipHandler::zip_file_open(const char* filename, zip_file**
|
||||||
goto error;
|
goto error;
|
||||||
}
|
}
|
||||||
|
|
||||||
strcpy(string, filename);
|
strcpy_s(string, strlen(filename) + 1, filename);
|
||||||
newzip->filename = string;
|
newzip->filename = string;
|
||||||
*zip = newzip;
|
*zip = newzip;
|
||||||
|
|
||||||
|
|
|
@ -689,7 +689,7 @@ void PromptWidget::textPaste()
|
||||||
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||||
void PromptWidget::addToHistory(const char* str)
|
void PromptWidget::addToHistory(const char* str)
|
||||||
{
|
{
|
||||||
strncpy(_history[_historyIndex], str, kLineBufferSize-1); //FIXME - unsafe function
|
strncpy_s(_history[_historyIndex], str, kLineBufferSize - 1);
|
||||||
_historyIndex = (_historyIndex + 1) % kHistorySize;
|
_historyIndex = (_historyIndex + 1) % kHistorySize;
|
||||||
_historyLine = 0;
|
_historyLine = 0;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue