summaryrefslogtreecommitdiff
path: root/core/multimedia/opieplayer/modplug/sndfile.cpp
Unidiff
Diffstat (limited to 'core/multimedia/opieplayer/modplug/sndfile.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--core/multimedia/opieplayer/modplug/sndfile.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/core/multimedia/opieplayer/modplug/sndfile.cpp b/core/multimedia/opieplayer/modplug/sndfile.cpp
index 1d0d610..799555c 100644
--- a/core/multimedia/opieplayer/modplug/sndfile.cpp
+++ b/core/multimedia/opieplayer/modplug/sndfile.cpp
@@ -1736,13 +1736,16 @@ void CSoundFile::CheckCPUUsage(UINT nCPU)
1736 1736
1737BOOL CSoundFile::SetPatternName(UINT nPat, LPCSTR lpszName) 1737BOOL CSoundFile::SetPatternName(UINT nPat, LPCSTR lpszName)
1738//--------------------------------------------------------- 1738//---------------------------------------------------------
1739{ 1739{
1740 char szName[MAX_PATTERNNAME] = ""; // changed from CHAR 1740 char szName[MAX_PATTERNNAME] = ""; // changed from CHAR
1741 if (nPat >= MAX_PATTERNS) return FALSE; 1741 if (nPat >= MAX_PATTERNS) return FALSE;
1742 if (lpszName) lstrcpyn(szName, lpszName, MAX_PATTERNNAME); 1742 if (lpszName)
1743 lstrcpyn(szName, lpszName, MAX_PATTERNNAME);
1744 else
1745 return FALSE;
1743 szName[MAX_PATTERNNAME-1] = 0; 1746 szName[MAX_PATTERNNAME-1] = 0;
1744 if (!m_lpszPatternNames) m_nPatternNames = 0; 1747 if (!m_lpszPatternNames) m_nPatternNames = 0;
1745 if (nPat >= m_nPatternNames) 1748 if (nPat >= m_nPatternNames)
1746 { 1749 {
1747 if (!lpszName[0]) return TRUE; 1750 if (!lpszName[0]) return TRUE;
1748 UINT len = (nPat+1)*MAX_PATTERNNAME; 1751 UINT len = (nPat+1)*MAX_PATTERNNAME;