overlapped |= FILE_FLAG_NO_BUFFERING;
if (!(flags & BDRV_O_CACHE_WB))
overlapped |= FILE_FLAG_WRITE_THROUGH;
+#ifdef CONFIG_MARU
s->hfile = CreateFile(g_win32_locale_filename_from_utf8(filename),
access_flags,
FILE_SHARE_READ, NULL,
OPEN_EXISTING, overlapped, NULL);
+#endif
if (s->hfile == INVALID_HANDLE_VALUE) {
int err = GetLastError();
overlapped |= FILE_FLAG_NO_BUFFERING;
if (!(flags & BDRV_O_CACHE_WB))
overlapped |= FILE_FLAG_WRITE_THROUGH;
+#ifdef CONFIG_MARU
s->hfile = CreateFile(g_win32_locale_filename_from_utf8(filename),
access_flags,
FILE_SHARE_READ, NULL,
create_flags, overlapped, NULL);
+#endif
if (s->hfile == INVALID_HANDLE_VALUE) {
int err = GetLastError();
USERMODEDEVICEDIR,
device_guid,
TAPSUFFIX);
-
+#ifdef CONFIG_MARU
handle = CreateFile (
g_win32_locale_filename_from_utf8(device_path),
GENERIC_READ | GENERIC_WRITE,
OPEN_EXISTING,
FILE_ATTRIBUTE_SYSTEM | FILE_FLAG_OVERLAPPED,
0 );
-
+#endif
if (handle == INVALID_HANDLE_VALUE) {
return -1;
}
OVERLAPPED overlap;
BOOL ret;
memset(&overlap, 0, sizeof(overlap));
-
+#ifdef CONFIG_MARU
file = CreateFile(g_win32_locale_filename_from_utf8(filename), GENERIC_WRITE, FILE_SHARE_READ, NULL,
OPEN_ALWAYS, FILE_ATTRIBUTE_NORMAL, NULL);
-
+#endif
if (file == INVALID_HANDLE_VALUE) {
return -1;
}
fprintf(stderr, "Failed CreateEvent\n");
goto fail;
}
-
+#ifdef CONFIG_MARU
s->hcom = CreateFile(g_win32_locale_filename_from_utf8(filename),
GENERIC_READ|GENERIC_WRITE, 0, NULL,
OPEN_EXISTING, FILE_FLAG_OVERLAPPED, 0);
+#endif
if (s->hcom == INVALID_HANDLE_VALUE) {
fprintf(stderr, "Failed CreateFile (%lu)\n", GetLastError());
s->hcom = NULL;
#ifndef CONFIG_MARU
fd_out = CreateFile(g_win32_locale_filename_from_utf8(file_out), GENERIC_WRITE, FILE_SHARE_READ, NULL,
OPEN_ALWAYS, FILE_ATTRIBUTE_NORMAL, NULL);
-#else
- fd_out = CreateFile(g_win32_locale_filename_from_utf8(file_out), GENERIC_WRITE, FILE_SHARE_READ, NULL,
- CREATE_ALWAYS, FILE_ATTRIBUTE_NORMAL, NULL);
#endif
if (fd_out == INVALID_HANDLE_VALUE) {
return -EIO;
addr.sin_port = htons(port);
if (((s = qemu_socket(AF_INET,SOCK_STREAM,0)) < 0) ||
- (bind(s,(struct sockaddr *)&addr, sizeof(addr)) < 0) ||
(setsockopt(s,SOL_SOCKET,SO_REUSEADDR,(char *)&opt,sizeof(int)) < 0) ||
+ (bind(s,(struct sockaddr *)&addr, sizeof(addr)) < 0) ||
(listen(s,1) < 0)) {
/* fail */
}
if( tizen_base_port != port ){
- ERR( "sdb port is miss match. Aborting\n" );
+ ERR( "sdb port is miss match. Aborting port :%d, tizen_base_port: %d\n", port, tizen_base_port);
exit(1);
}