summaryrefslogtreecommitdiff
path: root/fluid/ExternalCodeEditor_WIN32.cxx
diff options
context:
space:
mode:
authorMatthias Melcher <github@matthiasm.com>2022-11-26 01:35:50 +0100
committerGitHub <noreply@github.com>2022-11-26 01:35:50 +0100
commit6e5c472cf9641426c5425ea2f404e8908d76d63e (patch)
tree0f7ec46f88f01257702f1f9a7c8323a7fdc768c3 /fluid/ExternalCodeEditor_WIN32.cxx
parentc1a7c4af042a593b4b3a1df3e750b0cc80362486 (diff)
Handle Fluid project settings better (#556)
Fix allocation bug in Fl_String
Diffstat (limited to 'fluid/ExternalCodeEditor_WIN32.cxx')
-rw-r--r--fluid/ExternalCodeEditor_WIN32.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/fluid/ExternalCodeEditor_WIN32.cxx b/fluid/ExternalCodeEditor_WIN32.cxx
index f226450e3..175a6e5b2 100644
--- a/fluid/ExternalCodeEditor_WIN32.cxx
+++ b/fluid/ExternalCodeEditor_WIN32.cxx
@@ -22,6 +22,7 @@
#include <FL/fl_string_functions.h> // fl_strdup()
#include "ExternalCodeEditor_WIN32.h"
+#include "fluid.h"
#include <stdio.h> // snprintf()
#include <stdlib.h>
@@ -358,8 +359,7 @@ const char* ExternalCodeEditor::tmp_filename() {
static char path[512];
const char *tmpdir = create_tmpdir();
if ( !tmpdir ) return 0;
- extern const char *code_file_name; // fluid's global
- const char *ext = code_file_name; // e.g. ".cxx"
+ const char *ext = P.code_file_name; // e.g. ".cxx"
_snprintf(path, sizeof(path), "%s\\%p%s", tmpdir, (void*)this, ext);
path[sizeof(path)-1] = 0;
return path;