Callback functions for shutdown()?
まだ誰も着手していません。
- 主要言語
- C++
- スター
- 2.2k
- フォーク
- 242
- 平均マージ
- 11分
- マージ済み PR(30日)
- 1
説明
Hi, I encountered an issue that seems need some customization to the shutdown() function:
I have a separate thread initiated and detached before polyscope::init() -- a server listening from other software for sending geometries in.
The server use a shared_ptr<UIState> which is also used in the main().
Now if I close the main window of polyscope, there's always an error pointing to the ~shared_ptr<UIState>.
I'm not 100% sure what happened there, but it seems the main thread delete the shared_ptr<UIState> before the other thread exit. And when the server tries to delete that shared_ptr, it points to nowhere?
I assume manually exit the separate thread before the main should help.
コントリビューションガイド
このリポジトリのコントリビューションガイドは索引されていません
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
調査の方向性
shutdown() のエントリポイントと、レポートで説明されている UIState の所有権およびライフタイムの経路を確認してください。シャットダウンフックによって、共有状態が破棄される前にデタッチされたサーバーを停止できるようにする方法を特定し、その後、報告されている shared_ptr エラーなしでメインウィンドウの終了が完了することを検証してください。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- cpp
- 領域
- desktop
- issue の種類
- 機能追加
- 難易度
- 5/5
- 見積もり時間
- 1週間以上
- 活発さ
- 停滞
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 25/100