#include <pthread.h>
#endif
-#ifdef _MSC_VER
-#define inline
-#endif
#ifdef DBUS_USE_OUTPUT_DEBUG_STRING
static char module_name[1024];
#endif
static char *_dbus_file_path_extract_elements_from_tail(const char *file,int level)
{
static int prefix = -1;
- char *p;
if (prefix == -1)
{
#endif
vsprintf (buf+strlen(buf),format, args);
va_end (args);
- OutputDebugString(buf);
+ OutputDebugStringA(buf);
}
#else
#ifdef DBUS_CPP_SUPPORTS_VARIABLE_MACRO_ARGUMENTS
goto error;
}
- /* FIXME this is racy; we need a save_file_exclusively
- * function. But in practice this should be fine for now.
- *
- * - first be sure we can create the file and it
- * doesn't exist by creating it empty with O_EXCL
- * - then create it by creating a temporary file and
- * overwriting atomically with rename()
- */
- if (!_dbus_create_file_exclusively (filename, error))
- goto error;
-
if (!_dbus_string_append_byte (&encoded, '\n'))
{
_DBUS_SET_OOM (error);
goto error;
}
- if (!_dbus_string_save_to_file (&encoded, filename, error))
- goto error;
-
- if (!_dbus_make_file_world_readable (filename, error))
+ if (!_dbus_string_save_to_file (&encoded, filename, TRUE, error))
goto error;
_dbus_string_free (&encoded);