[vlc-devel] commit: Memory error handling ( Rémi Denis-Courmont )
git version control
git at videolan.org
Sun Aug 24 20:15:05 CEST 2008
vlc | branch: master | Rémi Denis-Courmont <rdenis at simphalempin.com> | Sun Aug 24 21:15:56 2008 +0300| [a06aeb0a485e6f69f6334dd2f5a5a366c03cb793] | committer: Rémi Denis-Courmont
Memory error handling
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=a06aeb0a485e6f69f6334dd2f5a5a366c03cb793
---
include/vlc_charset.h | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/include/vlc_charset.h b/include/vlc_charset.h
index 76d9a03..5bd3faa 100644
--- a/include/vlc_charset.h
+++ b/include/vlc_charset.h
@@ -72,7 +72,8 @@ static inline char *FromWide (const wchar_t *wide)
char *out = (char *)malloc (len);
- WideCharToMultiByte (CP_UTF8, 0, wide, -1, out, len, NULL, NULL);
+ if (out)
+ WideCharToMultiByte (CP_UTF8, 0, wide, -1, out, len, NULL, NULL);
return out;
}
#endif
More information about the vlc-devel
mailing list