<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>t_suwa</author_name>
  <author_url>https://blog.hatena.ne.jp/t_suwa/</author_url>
  <blog_title>AquaSKK 開発日記</blog_title>
  <blog_url>https://t-suwa.hatenadiary.org/</blog_url>
  <categories>
  </categories>
  <description>SKK 辞書の初期化を非同期化して検索のテストしているのですが、辞書のロードが完了する前に検索が走る現象がちらほら出てきました。検索が空振りするのでテストも失敗します。対策が必要です。検索時にコンテナが空かどうか確認するのはどうだろう。できれば、ロードが完了するまでそのまま待っていて欲しい。でも無限に待たれても困るので、せいぜい 3 秒くらいでタイムアウトして欲しい。こうなると、普通の mutex だけで実現するのは難しそうです。pthread を調べてみると、まさにこういった目的のために condition という仕組みが用意されていました。とはいえ、pthread の API を生のまま叩…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Ft-suwa.hatenadiary.org%2Fentry%2F20080229&quot; title=&quot;pthread の condition - AquaSKK 開発日記&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2008-02-29 00:00:00</published>
  <title>pthread の condition</title>
  <type>rich</type>
  <url>https://t-suwa.hatenadiary.org/entry/20080229</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
