mirror of
https://github.com/aseprite/aseprite.git
synced 2025-02-22 15:39:52 +00:00
Fix compilation problem on Linux (fix #604)
This commit is contained in:
parent
15b0b86339
commit
f3309ec52b
@ -1,5 +1,5 @@
|
||||
// Aseprite Base Library
|
||||
// Copyright (c) 2001-2013 David Capello
|
||||
// Copyright (c) 2001-2013, 2015 David Capello
|
||||
//
|
||||
// This file is released under the terms of the MIT license.
|
||||
// Read LICENSE.txt for more information.
|
||||
@ -11,6 +11,7 @@
|
||||
#include "base/exception.h"
|
||||
|
||||
#include <cstdio>
|
||||
#include <cstring>
|
||||
#include <cstdarg>
|
||||
|
||||
namespace base {
|
||||
@ -24,7 +25,7 @@ Exception::Exception() throw()
|
||||
Exception::Exception(const char* format, ...) throw()
|
||||
{
|
||||
try {
|
||||
if (!strchr(format, '%')) {
|
||||
if (!std::strchr(format, '%')) {
|
||||
m_msg = format;
|
||||
}
|
||||
else {
|
||||
@ -32,7 +33,7 @@ Exception::Exception(const char* format, ...) throw()
|
||||
va_start(ap, format);
|
||||
|
||||
char buf[1024]; // TODO warning buffer overflow
|
||||
vsprintf(buf, format, ap);
|
||||
std::vsprintf(buf, format, ap);
|
||||
m_msg = buf;
|
||||
|
||||
va_end(ap);
|
||||
|
Loading…
x
Reference in New Issue
Block a user