diff options
| author | nat-goodspeed <nat@lindenlab.com> | 2023-05-10 09:14:14 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-05-10 09:14:14 -0400 |
| commit | 69d444826d1feb58ae48f893083e22c01a50a93f (patch) | |
| tree | 73c20febab8061217597ce21560152c800f7c7ab /indra/llimage | |
| parent | 0b1c0aa242db6e789e0706f5ebfb9c80f98da9d3 (diff) | |
| parent | f728808d938666a01f73a039c861358fc4b02a9e (diff) | |
Merge pull request #208 from secondlife/SL-19690
SL-19690: Follow up on Rye Mutt's fix for shutdown crashes.
Diffstat (limited to 'indra/llimage')
| -rw-r--r-- | indra/llimage/llimageworker.cpp | 28 |
1 files changed, 13 insertions, 15 deletions
diff --git a/indra/llimage/llimageworker.cpp b/indra/llimage/llimageworker.cpp index 9358a0ae2c..520c81a8ec 100644 --- a/indra/llimage/llimageworker.cpp +++ b/indra/llimage/llimageworker.cpp @@ -92,21 +92,19 @@ LLImageDecodeThread::handle_t LLImageDecodeThread::decodeImage( { LL_PROFILE_ZONE_SCOPED_CATEGORY_TEXTURE; - try - { - // Instantiate the ImageRequest right in the lambda, why not? - mThreadPool->getQueue().post( - [req = ImageRequest(image, discard, needs_aux, responder)] - () mutable - { - auto done = req.processRequest(); - req.finishRequest(done); - }); - } - catch (const LLThreadSafeQueueInterrupt&) - { - LL_DEBUGS() << "Tried to start decoding on shutdown" << LL_ENDL; - } + // Instantiate the ImageRequest right in the lambda, why not? + bool posted = mThreadPool->getQueue().post( + [req = ImageRequest(image, discard, needs_aux, responder)] + () mutable + { + auto done = req.processRequest(); + req.finishRequest(done); + }); + if (! posted) + { + LL_DEBUGS() << "Tried to start decoding on shutdown" << LL_ENDL; + // should this return 0? + } // It's important to our consumer (LLTextureFetchWorker) that we return a // nonzero handle. It is NOT important that the nonzero handle be unique: |
