Replace a dubious manual return-value-optimization by a standard named-return-value-optimization to simplify leak detection.

This commit is contained in:
Adam Reichold
2015-11-28 14:30:38 +01:00
parent 1ed09dc049
commit e52ce5c485
3 changed files with 23 additions and 21 deletions

View File

@@ -306,8 +306,6 @@ public:
class ExifManager
{
static std::vector<Tag*> defTags;
static Tag* saveCIFFMNTag (FILE* f, TagDirectory* root, int len, const char* name);
public:
static TagDirectory* parse (FILE*f, int base, bool skipIgnored = true);
@@ -316,7 +314,10 @@ public:
static TagDirectory* parseCIFF (FILE* f, int base, int length);
static void parseCIFF (FILE* f, int base, int length, TagDirectory* root);
static const std::vector<Tag*>& getDefaultTIFFTags (TagDirectory* forthis);
/// @brief Get default tag for TIFF
/// @param forthis The byte order will be taken from the given directory.
/// @return The ownership of the return tags is passed to the caller.
static std::vector<Tag*> getDefaultTIFFTags (TagDirectory* forthis);
static int createJPEGMarker (const TagDirectory* root, const rtengine::procparams::ExifPairs& changeList, int W, int H, unsigned char* buffer);
static int createTIFFHeader (const TagDirectory* root, const rtengine::procparams::ExifPairs& changeList, int W, int H, int bps, const char* profiledata, int profilelen, const char* iptcdata, int iptclen, unsigned char* buffer);
};