return tmpnam(str);
}
-const char *platform_getenv(char *var) {
+const char *platform_getenv(const char *var) {
return getenv(var);
}
return tmpnam_s(str, L_tmpnam);
}
-const char *platform_getenv(char *var) {
+const char *platform_getenv(const char *var) {
char *buffer = (char *)platform_mem_allocate(GETENV_BUFFER);
size_t size;
getenv_s(&size, buffer, GETENV_BUFFER, var);
static void opts_setdefault(void) {
memset(&opts, 0, sizeof(opts_cmd_t));
OPTS_OPTION_BOOL(OPTION_CORRECTION) = true;
- OPTS_OPTION_STR(OPTION_PROGSRC) = "progs.src";
+ OPTS_OPTION_STR(OPTION_PROGSRC) = (char*)"progs.src";
/* warnings */
opts_set(opts.warn, WARN_UNUSED_VARIABLE, true);
* pointer. The return value is *NULL* if `var` is not found in the
* enviroment table.
*/
-const char *platform_getenv(char *var);
+const char *platform_getenv(const char *var);
/*
* Function: platform_vasprintf