diff --git a/sdk/tools/tools.h b/sdk/tools/tools.h index fd21807cbf6..7531020771b 100644 --- a/sdk/tools/tools.h +++ b/sdk/tools/tools.h @@ -382,14 +382,6 @@ static inline char *make_temp_dir(void) char *name; const char *tmpdir = NULL; -#ifdef __REACTOS__ -#ifdef _WIN32 - if (!(tmpdir = getenv("TEMP"))) tmpdir = "temp"; -#else - if (!(tmpdir = getenv("TMPDIR"))) tmpdir = "/tmp"; -#endif -#endif - for (count = 0; count < 0x8000; count++) { if (tmpdir) @@ -400,7 +392,11 @@ static inline char *make_temp_dir(void) value += 7777; if (errno == EACCES && !tmpdir) { +#if defined(__REACTOS__) && defined(_WIN32) + if (!(tmpdir = getenv("TEMP"))) tmpdir = "temp"; +#else if (!(tmpdir = getenv("TMPDIR"))) tmpdir = "/tmp"; +#endif } free( name ); } diff --git a/sdk/tools/widl/parser.y b/sdk/tools/widl/parser.y index 0e879688d58..c2ee30cc32c 100644 --- a/sdk/tools/widl/parser.y +++ b/sdk/tools/widl/parser.y @@ -2157,7 +2157,7 @@ static type_t *reg_typedefs( struct location where, decl_spec_t *decl_spec, decl type->attrs = attrs; } -#ifdef __REACTOS__ /* r53187 / 5bf224e */ +#ifdef __REACTOS__ /* r53187 / 5bf224e */ /* Append the SWITCHTYPE attribute to a non-encapsulated union if it does not already have it. */ if (type_get_type_detect_alias(type) == TYPE_UNION && is_attr(attrs, ATTR_SWITCHTYPE) && diff --git a/sdk/tools/widl/widl.c b/sdk/tools/widl/widl.c index 19348c70dc3..da755dfaf01 100644 --- a/sdk/tools/widl/widl.c +++ b/sdk/tools/widl/widl.c @@ -686,13 +686,11 @@ int open_typelib( const char *name ) TRYOPEN( strmake( "%s/wine%s/%s", libdir, pe_dir, name )); TRYOPEN( strmake( "%s/wine/%s", libdir, name )); } -#ifndef __REACTOS__ for (i = 0; i < ARRAY_SIZE(default_dirs); i++) { if (i && !strcmp( default_dirs[i], default_dirs[0] )) continue; TRYOPEN( strmake( "%s%s/%s", default_dirs[i], pe_dir, name )); } -#endif } #endif