Fixes for gcc compilation

This commit is contained in:
jeblanchard 2008-06-03 05:35:39 +00:00
parent 7173b5e2cb
commit f062107e60
2 changed files with 3 additions and 2 deletions

View File

@ -1242,7 +1242,7 @@ std::fstream* FCEUD_UTF8_fstream(const char *n, const char *m)
FCEUD_MakePathDirs(n);
}
std::ios_base::open_mode mode = std::ios_base::binary;
std::ios_base::openmode mode = std::ios_base::binary;
if(!strcmp(m,"r"))
mode |= std::ios_base::in;
else if(!strcmp(m,"w"))

View File

@ -1,6 +1,7 @@
#include <iostream>
#include <vector>
#include <sstream>
#include <stdexcept>
template<typename T>
class memory_streambuf: public std::streambuf {
@ -154,7 +155,7 @@ private:
void expand(size_t upto)
{
if(!myBuf && !usevec)
throw new std::exception("memory_streambuf is not expandable");
throw new std::runtime_error("memory_streambuf is not expandable");
size_t newcapacity;
if(upto == -1)