<feed xmlns='http://www.w3.org/2005/Atom'>
<title>dcpomatic/src/lib/update_checker.cc, branch main</title>
<subtitle>DCP-o-matic DCP tools</subtitle>
<id>https://git.carlh.net/cgit/dcpomatic/atom?h=main</id>
<link rel='self' href='https://git.carlh.net/cgit/dcpomatic/atom?h=main'/>
<link rel='alternate' type='text/html' href='https://git.carlh.net/cgit/dcpomatic/'/>
<updated>2023-03-29T23:25:25Z</updated>
<entry>
<title>Use CURLOPT_NOSIGNAL to fix crashes on update check (#2495).</title>
<updated>2023-03-29T23:25:25Z</updated>
<author>
<name>Carl Hetherington</name>
<email>cth@carlh.net</email>
</author>
<published>2023-03-29T23:25:25Z</published>
<link rel='alternate' type='text/html' href='https://git.carlh.net/cgit/dcpomatic/commit/?id=0fab37d3b61eb150b3de4a4000b8156e6e53574b'/>
<id>urn:sha1:0fab37d3b61eb150b3de4a4000b8156e6e53574b</id>
<content type='text'>
Without this, it's possible to come back from curl_easy_perform
in a different thread to the one that it was called from (in the case
of an error).

As I understand it, this happens because a signal handler is called
(from a different thread) and CURLOPT_NOSIGNAL stops this from
happening.
</content>
</entry>
<entry>
<title>Replace some raw arrays with std::vectors.</title>
<updated>2022-05-01T22:22:43Z</updated>
<author>
<name>Carl Hetherington</name>
<email>cth@carlh.net</email>
</author>
<published>2021-10-11T17:55:06Z</published>
<link rel='alternate' type='text/html' href='https://git.carlh.net/cgit/dcpomatic/commit/?id=809bcfd85fad2ef7d4131c054be4cccd5bcc9d05'/>
<id>urn:sha1:809bcfd85fad2ef7d4131c054be4cccd5bcc9d05</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Don't abort the update checker thread when one curl_easy_perform fails.</title>
<updated>2021-07-02T21:37:00Z</updated>
<author>
<name>Carl Hetherington</name>
<email>cth@carlh.net</email>
</author>
<published>2021-07-02T21:37:00Z</published>
<link rel='alternate' type='text/html' href='https://git.carlh.net/cgit/dcpomatic/commit/?id=16e560c3815b52609de103b45c1d5d2cbf155b97'/>
<id>urn:sha1:16e560c3815b52609de103b45c1d5d2cbf155b97</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Remove unused variable.</title>
<updated>2021-06-30T23:22:29Z</updated>
<author>
<name>Carl Hetherington</name>
<email>cth@carlh.net</email>
</author>
<published>2021-06-30T23:22:29Z</published>
<link rel='alternate' type='text/html' href='https://git.carlh.net/cgit/dcpomatic/commit/?id=eff6f92fe5d63ba067ef4eac21c2a82e5fb58197'/>
<id>urn:sha1:eff6f92fe5d63ba067ef4eac21c2a82e5fb58197</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Assorted C++11 tidying.</title>
<updated>2021-02-17T16:33:35Z</updated>
<author>
<name>Carl Hetherington</name>
<email>cth@carlh.net</email>
</author>
<published>2021-02-17T16:33:35Z</published>
<link rel='alternate' type='text/html' href='https://git.carlh.net/cgit/dcpomatic/commit/?id=33e13c4053138930f4b2f59349e441c76111059d'/>
<id>urn:sha1:33e13c4053138930f4b2f59349e441c76111059d</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Fix bugs in thread termination causing occasional pthread</title>
<updated>2020-07-29T18:22:54Z</updated>
<author>
<name>Carl Hetherington</name>
<email>cth@carlh.net</email>
</author>
<published>2020-07-29T18:22:54Z</published>
<link rel='alternate' type='text/html' href='https://git.carlh.net/cgit/dcpomatic/commit/?id=e3c7656f9dc0acbaf518c051b847ee2e4eb7ba23'/>
<id>urn:sha1:e3c7656f9dc0acbaf518c051b847ee2e4eb7ba23</id>
<content type='text'>
assertion failures.

Before this, it was possible for J2KEncoder::terminate_threads()
to finish without terminating all threads if the thread _running_
terminate_threads() was itself interrupt()ed.

This is because the thread_group::join_all() in terminate_threads()
is an interruption point, so it was possible it not to complete
but instead to throw interrupted_exception.  Then the owning
J2KEncoder would be torn down but the threads would still be running,
causing use-after-frees.

This commit adds some boost::this_thread::disable_interruption
objects to ensure that the owning thread is not interrupted while
it is being destroyed.

Also tidy up code that does this stuff, assuming that it's safe
to not call thread::joinable but instead do

thread.interrupt();
try {
  thread.join();
} catch (...) {}
</content>
</entry>
<entry>
<title>Various thread cleanups.</title>
<updated>2020-01-30T21:54:38Z</updated>
<author>
<name>Carl Hetherington</name>
<email>cth@carlh.net</email>
</author>
<published>2020-01-30T21:54:38Z</published>
<link rel='alternate' type='text/html' href='https://git.carlh.net/cgit/dcpomatic/commit/?id=ea6b2dae46caa1da829fbf499e83cd6ae3b3773a'/>
<id>urn:sha1:ea6b2dae46caa1da829fbf499e83cd6ae3b3773a</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Fix update check (#1338).</title>
<updated>2018-07-14T20:54:12Z</updated>
<author>
<name>Carl Hetherington</name>
<email>cth@carlh.net</email>
</author>
<published>2018-07-14T20:52:32Z</published>
<link rel='alternate' type='text/html' href='https://git.carlh.net/cgit/dcpomatic/commit/?id=9f4b7dd032e4d588720d46f858171c7f087f3e23'/>
<id>urn:sha1:9f4b7dd032e4d588720d46f858171c7f087f3e23</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Fix update checket error when there is no test version.</title>
<updated>2018-03-24T22:46:05Z</updated>
<author>
<name>Carl Hetherington</name>
<email>cth@carlh.net</email>
</author>
<published>2018-03-24T22:45:53Z</published>
<link rel='alternate' type='text/html' href='https://git.carlh.net/cgit/dcpomatic/commit/?id=3d15e81de19a57eb8c6a308e00ea07c542068b58'/>
<id>urn:sha1:3d15e81de19a57eb8c6a308e00ea07c542068b58</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Name threads on Linux.</title>
<updated>2018-02-16T20:24:37Z</updated>
<author>
<name>Carl Hetherington</name>
<email>cth@carlh.net</email>
</author>
<published>2018-02-16T20:24:37Z</published>
<link rel='alternate' type='text/html' href='https://git.carlh.net/cgit/dcpomatic/commit/?id=8e4a2e5ea578ac4f0f41edb6145d5c0040e33ec2'/>
<id>urn:sha1:8e4a2e5ea578ac4f0f41edb6145d5c0040e33ec2</id>
<content type='text'>
</content>
</entry>
</feed>
