flathub / flathub/com.github.PintaProject.Pinta

Unhandled error message when using "save as" on files outside the user directory

オープン
#34 コメント 2 件 リアクション 0 件 担当者 0 名 GitHub で見る
主要言語
言語のデータがありません
スター
4
フォーク
4
PR マージ指標
30日以内にマージされた PR はありません

説明

When I open an image outside my user directory and then choose "save as" I get the following error message:
`System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation.
---> System.NullReferenceException: Object reference not set to an instance of an object.
at Pinta.Actions.SaveDocumentImplmentationAction.SaveFileAs(Document document)
at Pinta.Actions.SaveDocumentImplmentationAction.Activated(Object sender, DocumentCancelEventArgs e)
at Pinta.Core.FileActions.RaiseSaveDocument(Document document, Boolean saveAs)
at Pinta.Core.Document.Save(Boolean saveAs)
at Pinta.Actions.SaveDocumentAsAction.Activated(Object sender, EventArgs e)
at Pinta.Core.Command.<.ctor>b__33_0(Object o, ActivatedArgs args)
at InvokeStub_ActivatedHandler.Invoke(Object, Object, IntPtr*)
at System.Reflection.MethodInvoker.Invoke(Object obj, IntPtr* args, BindingFlags invokeAttr)
--- End of inner exception stack trace ---
at System.Reflection.MethodInvoker.Invoke(Object obj, IntPtr* args, BindingFlags invokeAttr)
at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
at System.Delegate.DynamicInvokeImpl(Object[] args)
at GLib.Signal.ClosureInvokedCB(Object o, ClosureInvokedArgs args)
at GLib.SignalClosure.Invoke(ClosureInvokedArgs args)
at GLib.SignalClosure.MarshalCallback(IntPtr raw_closure, IntPtr return_val, UInt32 n_param_vals, IntPtr param_values, IntPtr invocation_hint, IntPtr marshal_data)`

Problem seems to be the pre-selected path of the sandbox in the format "/run/user//doc/". A simple "save" works though! Operating system is Debian 12 with flatpak in version 1.14.4 and pinta in 2.1.1!

Hope you can reproduce and fix it. Thanks in advance!

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

調査の方向性

Flatpak サンドボックスを使用して Debian 12 上の Pinta 2.1.1 で、ユーザーディレクトリ外にある画像を開いて Save as を選択することで問題を再現します。SaveDocumentImplmentationAction.SaveFileAs(Document document) から開始し、続いて SaveDocumentAsAction と FileActions.RaiseSaveDocument を追跡します。/run/user//doc/ パスに対して Save as が例外をスローしなくなり、通常の Save が引き続き機能すれば完了です。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
csharp, debian
領域
desktop, operating-systems
issue の種類
バグ
難易度
3/5
見積もり時間
1〜2日
活発さ
停滞
明瞭さ
おおむね明確
初心者へのやさしさ
38/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。