Improved FPrint(f) passthrough
This commit is contained in:
parent
c116353285
commit
5e7e7ce551
@ -93,7 +93,7 @@ public:
|
|||||||
virtual int Read(void* pOutput, int size, FileHandle_t file) = 0;
|
virtual int Read(void* pOutput, int size, FileHandle_t file) = 0;
|
||||||
virtual void Seek(FileHandle_t file, int post, int seekType) = 0;
|
virtual void Seek(FileHandle_t file, int post, int seekType) = 0;
|
||||||
virtual unsigned int Tell(FileHandle_t file) = 0;
|
virtual unsigned int Tell(FileHandle_t file) = 0;
|
||||||
virtual int WriteFileLine(FileHandle_t file, const char *pLine) = 0;
|
virtual int FPrint(FileHandle_t file, const char *pData) = 0;
|
||||||
virtual void Flush(FileHandle_t file) = 0;
|
virtual void Flush(FileHandle_t file) = 0;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -587,7 +587,7 @@ static cell_t sm_WriteFileLine(IPluginContext *pContext, const cell_t *params)
|
|||||||
FileHandle_t pFile = (FileHandle_t) pTempFile;
|
FileHandle_t pFile = (FileHandle_t) pTempFile;
|
||||||
smcore.atcprintf(buffer, sizeof(buffer), fmt, pContext, params, &arg);
|
smcore.atcprintf(buffer, sizeof(buffer), fmt, pContext, params, &arg);
|
||||||
sprintf(buffer, "%s\n", buffer);
|
sprintf(buffer, "%s\n", buffer);
|
||||||
smcore.filesystem->WriteFileLine(pFile, buffer);
|
smcore.filesystem->FPrint(pFile, buffer);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -186,9 +186,9 @@ public:
|
|||||||
{
|
{
|
||||||
return filesystem->Tell(file);
|
return filesystem->Tell(file);
|
||||||
}
|
}
|
||||||
int WriteFileLine(FileHandle_t file, const char *pLine)
|
int FPrint(FileHandle_t file, const char *pData)
|
||||||
{
|
{
|
||||||
return filesystem->FPrintf(file, pLine);
|
return filesystem->FPrintf(file, "%s", pData);
|
||||||
}
|
}
|
||||||
void Flush(FileHandle_t file)
|
void Flush(FileHandle_t file)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user