summaryrefslogtreecommitdiff
path: root/src/drivers/Android/Fl_Android_System_Driver.H
diff options
context:
space:
mode:
authorAlbrecht Schlosser <albrechts.fltk@online.de>2020-02-10 11:55:34 +0100
committerAlbrecht Schlosser <albrechts.fltk@online.de>2020-02-10 12:10:40 +0100
commit4c1b92eb52db567b4c1618222bb3007a2a2e7d9b (patch)
tree58081f8e02a8d43dc273de033d454c16e9946f28 /src/drivers/Android/Fl_Android_System_Driver.H
parentdcb848ca3ed0ebddd4f28888d2a8ab2f59c9fd1c (diff)
Implement fl_putenv() as cross-platform putenv()
Diffstat (limited to 'src/drivers/Android/Fl_Android_System_Driver.H')
-rw-r--r--src/drivers/Android/Fl_Android_System_Driver.H8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/drivers/Android/Fl_Android_System_Driver.H b/src/drivers/Android/Fl_Android_System_Driver.H
index ec6a6d4aa..e3ccb41bd 100644
--- a/src/drivers/Android/Fl_Android_System_Driver.H
+++ b/src/drivers/Android/Fl_Android_System_Driver.H
@@ -3,17 +3,17 @@
//
// Definition of Android system driver for the Fast Light Tool Kit (FLTK).
//
-// Copyright 2010-2018 by Bill Spitzak and others.
+// Copyright 2010-2020 by Bill Spitzak and others.
//
// This library is free software. Distribution and use rights are outlined in
// the file "COPYING" which should have been included with this file. If this
// file is missing or damaged, see the license at:
//
-// http://www.fltk.org/COPYING.php
+// https://www.fltk.org/COPYING.php
//
// Please report all bugs and problems on the following page:
//
-// http://www.fltk.org/str.php
+// https://www.fltk.org/str.php
//
/**
@@ -48,7 +48,7 @@ public:
virtual void fatal(const char *format, va_list args);
virtual char *utf2mbcs(const char *s);
virtual char *getenv(const char *var);
- virtual int putenv(char *var) {return ::putenv(var);} // *FIXME* needs string conversion
+ virtual int putenv(const char *var) { return ::putenv(strdup(var)); }
virtual int open(const char *fnam, int oflags, int pmode);
virtual int open_ext(const char *fnam, int binary, int oflags, int pmode);
virtual FILE *fopen(const char *fnam, const char *mode);