changed some spamming to trace

This commit is contained in:
georgemoralis 2024-06-10 18:56:10 +03:00
parent e576bc99ba
commit fa225b60fc
3 changed files with 7 additions and 5 deletions

View File

@ -90,6 +90,9 @@ int PS4_SYSV_ABI sceKernelClose(int d) {
} }
size_t PS4_SYSV_ABI sceKernelWrite(int d, void* buf, size_t nbytes) { size_t PS4_SYSV_ABI sceKernelWrite(int d, void* buf, size_t nbytes) {
if (buf == nullptr) {
return SCE_KERNEL_ERROR_EFAULT;
}
if (d <= 2) { // stdin,stdout,stderr if (d <= 2) { // stdin,stdout,stderr
char* str = strdup((const char*)buf); char* str = strdup((const char*)buf);
if (str[nbytes - 1] == '\n') if (str[nbytes - 1] == '\n')
@ -98,9 +101,6 @@ size_t PS4_SYSV_ABI sceKernelWrite(int d, void* buf, size_t nbytes) {
free(str); free(str);
return nbytes; return nbytes;
} }
if (buf == nullptr) {
return SCE_KERNEL_ERROR_EFAULT;
}
auto* h = Common::Singleton<Core::FileSys::HandleTable>::Instance(); auto* h = Common::Singleton<Core::FileSys::HandleTable>::Instance();
auto* file = h->GetFile(d); auto* file = h->GetFile(d);
if (file == nullptr) { if (file == nullptr) {

View File

@ -549,7 +549,7 @@ int PS4_SYSV_ABI scePthreadMutexUnlock(ScePthreadMutex* mutex) {
int result = pthread_mutex_unlock(&(*mutex)->pth_mutex); int result = pthread_mutex_unlock(&(*mutex)->pth_mutex);
if (result != 0) { if (result != 0) {
LOG_INFO(Kernel_Pthread, "name={}, result={}", (*mutex)->name, result); LOG_TRACE(Kernel_Pthread, "name={}, result={}", (*mutex)->name, result);
} }
switch (result) { switch (result) {
case 0: case 0:
@ -1133,7 +1133,7 @@ int PS4_SYSV_ABI scePthreadMutexTrylock(ScePthreadMutex* mutex) {
int result = pthread_mutex_trylock(&(*mutex)->pth_mutex); int result = pthread_mutex_trylock(&(*mutex)->pth_mutex);
if (result != 0) { if (result != 0) {
LOG_INFO(Kernel_Pthread, "name={}, result={}", (*mutex)->name, result); LOG_TRACE(Kernel_Pthread, "name={}, result={}", (*mutex)->name, result);
} }
switch (result) { switch (result) {
case 0: case 0:

View File

@ -102,6 +102,8 @@ void Emulator::Run(const std::filesystem::path& file) {
found = true; found = true;
LOG_INFO(Loader, "Loading {}", entry.path().string().c_str()); LOG_INFO(Loader, "Loading {}", entry.path().string().c_str());
linker->LoadModule(entry.path()); linker->LoadModule(entry.path());
} else {
LOG_ERROR(Loader, "Skipped loading module {}", entry.path().string().c_str());
} }
} }
} }