From d08754a8446f4d32f8d59d953b02ac856ccb54d5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Harri=20Pitk=C3=A4nen?= Date: Thu, 7 Oct 2010 15:37:39 +0100 Subject: [PATCH] [cppcheck] closes a file that would be left open if memory allocation fails --- sal/osl/unx/profile.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sal/osl/unx/profile.c b/sal/osl/unx/profile.c index c77a27543261..9f9a4de467e8 100644 --- a/sal/osl/unx/profile.c +++ b/sal/osl/unx/profile.c @@ -245,6 +245,7 @@ static oslProfile SAL_CALL osl_psz_openProfile(const sal_Char *pszProfileName, o if ( pProfile == 0 ) { + closeFileImpl(pFile, Flags); return 0; }