} while ((bytesWritten != bytesToWrite) && (EINTR == errno));
}
-int ssmEncrypt(InstallMode::RootPath rootPath, std::string pkgId, const char*
+int ssmEncrypt(InstallMode::InstallTime time, std::string pkgId, const char*
inChunk, int inBytes, char** outChunk, int *outBytes)
{
- if (rootPath == InstallMode::RootPath::RO) {
+ if (time == InstallMode::InstallTime::PRELOAD) {
return ssm_encrypt_preloaded_application(inChunk, inBytes,
outChunk, outBytes);
} else {
if (0 != bytesRead) {
int outDecSize = 0;
char *outChunk = NULL;
- if (0 != ssmEncrypt(m_context.mode.rootPath, pkgId,
+ if (0 != ssmEncrypt(m_context.mode.installTime, pkgId,
(char*)inChunk.get(), (int)bytesRead,
&outChunk, &outDecSize)) {
ThrowMsg(Exceptions::EncryptionFailed,