From 543e5dc1d2e936fa14917a9e400cebb81fce6639 Mon Sep 17 00:00:00 2001 From: Beq Date: Thu, 14 Jan 2021 01:57:09 +0000 Subject: [PATCH] Improve logging of looping apr poll error in slplugin won't change the issues but it should make the logging sane --- indra/llplugin/llpluginprocessparent.cpp | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/indra/llplugin/llpluginprocessparent.cpp b/indra/llplugin/llpluginprocessparent.cpp index bf7c7ddba2..3d21e7e55d 100644 --- a/indra/llplugin/llpluginprocessparent.cpp +++ b/indra/llplugin/llpluginprocessparent.cpp @@ -895,16 +895,24 @@ void LLPluginProcessParent::poll(F64 timeout) { // timed out with no incoming data. Just return. } - else if(status == EBADF) + // better logging of poll issues + // else if(status == EBADF) + else if(APR_STATUS_IS_EBADF(status)) { // This happens when one of the file descriptors in the pollset is destroyed, which happens whenever a plugin's socket is closed. // The pollset has been or will be recreated, so just return. LL_DEBUGS("PluginPoll") << "apr_pollset_poll returned EBADF" << LL_ENDL; } - else if(status != APR_SUCCESS) + // better logging of poll issues + // else if(status != APR_SUCCESS) + // { + // LL_WARNS("PluginPoll") << "apr_pollset_poll failed with status " << status << LL_ENDL; + // } + else { - LL_WARNS("PluginPoll") << "apr_pollset_poll failed with status " << status << LL_ENDL; + LL_WARNS("PluginPoll") << "apr_pollset_poll failed with status " << status << " (" << APR_TO_OS_ERROR(status) << ")" << LL_ENDL; } + // } // Remove instances in the done state from the sInstances map.