diff options
Diffstat (limited to 'rsc')
-rw-r--r-- | rsc/inc/rsctools.hxx | 2 | ||||
-rw-r--r-- | rsc/source/tools/rsctools.cxx | 39 |
2 files changed, 0 insertions, 41 deletions
diff --git a/rsc/inc/rsctools.hxx b/rsc/inc/rsctools.hxx index b2ad7c483e87..91a46dce284e 100644 --- a/rsc/inc/rsctools.hxx +++ b/rsc/inc/rsctools.hxx @@ -41,8 +41,6 @@ enum RSCBYTEORDER_TYPE { RSC_BIGENDIAN, RSC_LITTLEENDIAN, RSC_SYSTEMENDIAN }; // Function Forwards OString GetTmpFileName(); -bool Append(const OString &rDestFile, const OString &rSourceFile); - bool Append(FILE * fDest, OString &raSourceFile); OString OutputFile(const OString &rInput, const char * ext); diff --git a/rsc/source/tools/rsctools.cxx b/rsc/source/tools/rsctools.cxx index 45f29afe004a..51ce98ce5314 100644 --- a/rsc/source/tools/rsctools.cxx +++ b/rsc/source/tools/rsctools.cxx @@ -88,45 +88,6 @@ OString GetTmpFileName() return OUStringToOString( aTmpFile, RTL_TEXTENCODING_MS_1252 ); } -bool Append(FILE * fDest, const OString &rTmpFile) -{ -#define MAX_BUF 4096 - FILE *fSource = fopen(rTmpFile.getStr(), "rb"); - if( !fDest || !fSource ) - { - if( fSource ) - fclose( fSource ); - return false; - } - - bool bSuccess = true; - char szBuf[ MAX_BUF ]; - size_t nItems; - - do //append - { - nItems = fread( szBuf, 1, MAX_BUF, fSource ); - bSuccess = (nItems == fwrite(szBuf, 1, nItems, fDest)); - SAL_WARN_IF(!bSuccess, "rsc", "short write"); - } - while (MAX_BUF == nItems && bSuccess); - - fclose( fSource ); - return bSuccess; -} - -bool Append(const OString &rOutputSrs, const OString &rTmpFile) -{ - FILE * fDest = fopen(rOutputSrs.getStr(), "ab"); - - bool bRet = Append(fDest, rTmpFile); - - if( fDest ) - fclose( fDest ); - - return bRet; -} - /* replaces extension of a file name */ OString OutputFile(const OString &rInput, const char * pExt) { |