small fixes
git-svn-id: https://clonekeenplus.svn.sourceforge.net/svnroot/clonekeenplus/cgenius/trunk@86 4df4b0f3-56ce-47cb-b001-ed939b7d65a6
This commit is contained in:
@@ -48,7 +48,7 @@ bool CExeFile::readData()
|
|||||||
{
|
{
|
||||||
m_datasize = decdata->size();
|
m_datasize = decdata->size();
|
||||||
m_data = new unsigned char[m_datasize];
|
m_data = new unsigned char[m_datasize];
|
||||||
memcpy(m_data, decdata->data(), m_datasize);
|
memcpy(m_data, &decdata[0], m_datasize);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -20,8 +20,6 @@ CMusic::~CMusic() {
|
|||||||
|
|
||||||
int CMusic::load(SDL_AudioSpec AudioSpec, char *musicfile)
|
int CMusic::load(SDL_AudioSpec AudioSpec, char *musicfile)
|
||||||
{
|
{
|
||||||
FILE *fp;
|
|
||||||
|
|
||||||
if(AudioSpec.format != 0)
|
if(AudioSpec.format != 0)
|
||||||
{
|
{
|
||||||
|
|
||||||
@@ -35,6 +33,7 @@ int CMusic::load(SDL_AudioSpec AudioSpec, char *musicfile)
|
|||||||
pOggAudio.sound_len=0;
|
pOggAudio.sound_len=0;
|
||||||
pOggAudio.sound_pos=0;
|
pOggAudio.sound_pos=0;
|
||||||
|
|
||||||
|
FILE *fp;
|
||||||
if((fp = fopen(musicfile,"rb")) == NULL)
|
if((fp = fopen(musicfile,"rb")) == NULL)
|
||||||
{
|
{
|
||||||
g_pLogFile->textOut(PURPLE,"Music Driver(): \"%s\". File does not exist!<br>", musicfile);
|
g_pLogFile->textOut(PURPLE,"Music Driver(): \"%s\". File does not exist!<br>", musicfile);
|
||||||
|
|||||||
@@ -72,10 +72,8 @@ bool CEGAGraphics::loadData()
|
|||||||
}
|
}
|
||||||
HeadFile.close();
|
HeadFile.close();
|
||||||
|
|
||||||
char *data;
|
char *data = new char[databuf.size()];
|
||||||
data = new char[databuf.size()];
|
memcpy(data, &databuf[0], databuf.size());
|
||||||
|
|
||||||
memcpy(data, databuf.data(), databuf.size());
|
|
||||||
|
|
||||||
// Now copy the data to the EGAHEAD Structure
|
// Now copy the data to the EGAHEAD Structure
|
||||||
memcpy(&LatchPlaneSize,data,4);
|
memcpy(&LatchPlaneSize,data,4);
|
||||||
|
|||||||
Reference in New Issue
Block a user