Initial community commit
This commit is contained in:
parent
537bcbc862
commit
fc06254474
16440 changed files with 4239995 additions and 2 deletions
19
Src/external_dependencies/openmpt-trunk/include/unrar/smallfn.cpp
vendored
Normal file
19
Src/external_dependencies/openmpt-trunk/include/unrar/smallfn.cpp
vendored
Normal file
|
@ -0,0 +1,19 @@
|
|||
#include "rar.hpp"
|
||||
|
||||
int ToPercent(int64 N1,int64 N2)
|
||||
{
|
||||
if (N2<N1)
|
||||
return 100;
|
||||
return ToPercentUnlim(N1,N2);
|
||||
}
|
||||
|
||||
|
||||
// Allows the percent larger than 100.
|
||||
int ToPercentUnlim(int64 N1,int64 N2)
|
||||
{
|
||||
if (N2==0)
|
||||
return 0;
|
||||
return (int)(N1*100/N2);
|
||||
}
|
||||
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue