<p></p>
<h2>Steps to reproduce:</h2>
<ol>
<li>Open a document</li>
<li>File->Save As</li>
<li>Notice an interesting file in the list of files in the dialog</li>
<li>Open interesting file from the command-line (in another program) with <code>geany interesting-file</code>. The file opens in the background underneath the Save As dialog.</li>
<li>Type a new filename and click save</li>
</ol>
<p>The <code>interesting-file</code> document will have been saved with the new filename. The original document will still be open, unsaved.</p>
<h2>Cause</h2>
<p><code>handle_save_as</code> is dialogs.c uses <code>document_get_current</code>.</p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/geany/geany/issues/2599">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AAIOWJ3EL274JRAKJNO3OM3SIC53FANCNFSM4R4XZXVQ">unsubscribe</a>.<img src="https://github.com/notifications/beacon/AAIOWJ53HSZW6U2RHLRNPSLSIC53FA5CNFSM4R4XZXV2YY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4KSYJWQA.gif" height="1" width="1" alt="" /></p>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/geany/geany/issues/2599",
"url": "https://github.com/geany/geany/issues/2599",
"name": "View Issue"
},
"description": "View this Issue on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>