mirror of
https://gitee.com/openharmony/third_party_libsnd
synced 2024-11-26 19:40:24 +00:00
Octave/*.cc : Minor cleanups.
This commit is contained in:
parent
5ecea5a8d1
commit
86a91c5b3f
@ -47,7 +47,7 @@ hash_of_str (const std::string & str)
|
||||
{
|
||||
int hash = 0 ;
|
||||
|
||||
for (int k = 0 ; k < str.length () ; k++)
|
||||
for (unsigned k = 0 ; k < str.length () ; k++)
|
||||
hash = (hash * 3) + tolower (str [k]) ;
|
||||
|
||||
return hash ;
|
||||
|
@ -77,7 +77,7 @@ Read a sound file from disk using libsndfile.\n\
|
||||
if (total + readcount > sfinfo.frames)
|
||||
readcount = sfinfo.frames - total ;
|
||||
|
||||
for (unsigned ch = 0 ; ch < sfinfo.channels ; ch++)
|
||||
for (int ch = 0 ; ch < sfinfo.channels ; ch++)
|
||||
{ for (int k = 0 ; k < readcount ; k++)
|
||||
out (total + k, ch) = buffer [k * sfinfo.channels + ch] ;
|
||||
} ;
|
||||
|
Loading…
Reference in New Issue
Block a user