Fixed gcc compile warning.
git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@576 3789f03b-4d11-0410-bbf8-ca57d06f2519
diff --git a/rfb/SFTMsgReader.cxx b/rfb/SFTMsgReader.cxx
index b88467b..22787bf 100644
--- a/rfb/SFTMsgReader.cxx
+++ b/rfb/SFTMsgReader.cxx
@@ -70,7 +70,7 @@
return readU8U16U32StringMsg(&compressedLevel, pFilenameSize, pPosition, pFilename);
}
-void *
+char *
SFTMsgReader::readFileUploadData(unsigned int *pDataSize, unsigned int *pModTime)
{
unsigned char compressedLevel = m_pIS->readU8();
diff --git a/rfb/SFTMsgReader.h b/rfb/SFTMsgReader.h
index dff06a4..32ac869 100644
--- a/rfb/SFTMsgReader.h
+++ b/rfb/SFTMsgReader.h
@@ -46,7 +46,7 @@
bool readFileUploadRqst(unsigned int *pFilenameSize, char *pFilename,
unsigned int *pPosition);
- void *readFileUploadData(unsigned int *pDataSize, unsigned int *pModTime);
+ char *readFileUploadData(unsigned int *pDataSize, unsigned int *pModTime);
bool readFileCreateDirRqst(unsigned int *pDirNameSize, char *pDirName);
diff --git a/rfb/SFileTransfer.cxx b/rfb/SFileTransfer.cxx
index 6f444e9..957e50b 100644
--- a/rfb/SFileTransfer.cxx
+++ b/rfb/SFileTransfer.cxx
@@ -174,7 +174,7 @@
unsigned int dataSize = 0;
unsigned int modTime = 0;
- void *pUploadData = m_reader.readFileUploadData(&dataSize, &modTime);
+ char *pUploadData = m_reader.readFileUploadData(&dataSize, &modTime);
if (!m_bUploadStarted) {
char reason[] = "Upload is impossible";
@@ -200,9 +200,6 @@
}
}
}
- // FIXME: For the next line, gcc says:
- // warning: deleting `void *' is undefined
- // Perhaps it should not be `void *' at all.
delete [] pUploadData;
return true;
}