diff --git a/patches/server-Shared_Memory/0002-server-Implement-support-for-global-and-local-shared.patch b/patches/server-Shared_Memory/0002-server-Implement-support-for-global-and-local-shared.patch index 29e637cc..3dc0a495 100644 --- a/patches/server-Shared_Memory/0002-server-Implement-support-for-global-and-local-shared.patch +++ b/patches/server-Shared_Memory/0002-server-Implement-support-for-global-and-local-shared.patch @@ -1,4 +1,4 @@ -From d4226297d14857b3b5d069af8ba7437fc2504939 Mon Sep 17 00:00:00 2001 +From 6b5e2bec64faa4a6f8ba22c1607a9eef762cf039 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20M=C3=BCller?= Date: Thu, 19 Mar 2015 01:22:34 +0100 Subject: server: Implement support for global and local shared memory blocks @@ -20,7 +20,7 @@ Subject: server: Implement support for global and local shared memory blocks 12 files changed, 215 insertions(+), 1 deletion(-) diff --git a/dlls/ntdll/ntdll_misc.h b/dlls/ntdll/ntdll_misc.h -index 41ef5cb..18e00c9 100644 +index 7eded42..79cc2c1 100644 --- a/dlls/ntdll/ntdll_misc.h +++ b/dlls/ntdll/ntdll_misc.h @@ -97,6 +97,7 @@ extern int server_remove_fd_from_cache( HANDLE handle ) DECLSPEC_HIDDEN; @@ -32,10 +32,10 @@ index 41ef5cb..18e00c9 100644 /* security descriptors */ NTSTATUS NTDLL_create_struct_sd(PSECURITY_DESCRIPTOR nt_sd, struct security_descriptor **server_sd, diff --git a/dlls/ntdll/server.c b/dlls/ntdll/server.c -index 69d01be..0b8e007 100644 +index 652a1aa..2e4fc6e 100644 --- a/dlls/ntdll/server.c +++ b/dlls/ntdll/server.c -@@ -941,6 +941,66 @@ done: +@@ -972,6 +972,66 @@ done: /*********************************************************************** @@ -102,7 +102,7 @@ index 69d01be..0b8e007 100644 * wine_server_fd_to_handle (NTDLL.@) * * Allocate a file handle for a Unix file descriptor. -@@ -1472,6 +1532,10 @@ size_t server_init_thread( void *entry_point ) +@@ -1503,6 +1563,10 @@ size_t server_init_thread( void *entry_point ) } SERVER_END_REQ; @@ -158,7 +158,7 @@ index d573d1f..695389a 100644 /* macros for server requests */ diff --git a/include/winternl.h b/include/winternl.h -index f88001f..f1cc143 100644 +index 9231468..3ecaef7 100644 --- a/include/winternl.h +++ b/include/winternl.h @@ -353,7 +353,7 @@ typedef struct _TEB @@ -171,10 +171,10 @@ index f88001f..f1cc143 100644 ULONG ImpersonationLocale; /* f98/1788 */ ULONG IsImpersonating; /* f9c/178c */ diff --git a/server/fd.c b/server/fd.c -index e3b722c..14c473b 100644 +index 1253b3d..08c052d 100644 --- a/server/fd.c +++ b/server/fd.c -@@ -2293,6 +2293,33 @@ DECL_HANDLER(get_handle_fd) +@@ -2328,6 +2328,33 @@ DECL_HANDLER(write) } } @@ -209,10 +209,10 @@ index e3b722c..14c473b 100644 DECL_HANDLER(ioctl) { diff --git a/server/file.h b/server/file.h -index 85e4257..9c110bc 100644 +index 603b686..c0debbd 100644 --- a/server/file.h +++ b/server/file.h -@@ -134,6 +134,14 @@ extern obj_handle_t open_mapping_file( struct process *process, struct mapping * +@@ -138,6 +138,14 @@ extern obj_handle_t open_mapping_file( struct process *process, struct mapping * extern struct mapping *grab_mapping_unless_removable( struct mapping *mapping ); extern int get_page_size(void); @@ -240,7 +240,7 @@ index 7aed338..f984bfc 100644 return 0; } diff --git a/server/mapping.c b/server/mapping.c -index 64b3003..063dbb8 100644 +index 16e7c1c..c180ae5 100644 --- a/server/mapping.c +++ b/server/mapping.c @@ -29,8 +29,32 @@ @@ -276,7 +276,7 @@ index 64b3003..063dbb8 100644 #include "ntstatus.h" #define WIN32_NO_STATUS #include "windef.h" -@@ -112,6 +136,10 @@ static struct list shared_list = LIST_INIT(shared_list); +@@ -114,6 +138,10 @@ static struct list shared_list = LIST_INIT(shared_list); static size_t page_mask; @@ -287,7 +287,7 @@ index 64b3003..063dbb8 100644 #define ROUND_SIZE(size) (((size) + page_mask) & ~page_mask) -@@ -156,6 +184,52 @@ static int check_current_dir_for_exec(void) +@@ -158,6 +186,52 @@ static int check_current_dir_for_exec(void) return (ret != MAP_FAILED); } @@ -341,7 +341,7 @@ index 64b3003..063dbb8 100644 static int create_temp_file( file_pos_t size ) { diff --git a/server/protocol.def b/server/protocol.def -index 2cd8272..91ba01d 100644 +index 9c4dab4..495365b 100644 --- a/server/protocol.def +++ b/server/protocol.def @@ -69,6 +69,15 @@ struct request_max_size @@ -360,7 +360,7 @@ index 2cd8272..91ba01d 100644 /* debug event data */ typedef union -@@ -1150,6 +1159,12 @@ enum server_fd_type +@@ -1170,6 +1179,12 @@ enum server_fd_type }; @@ -371,10 +371,10 @@ index 2cd8272..91ba01d 100644 + + /* Flush a file buffers */ - @REQ(flush_file) - obj_handle_t handle; /* handle to the file */ + @REQ(flush) + int blocking; /* whether it's a blocking flush */ diff --git a/server/thread.c b/server/thread.c -index 906b79d..f99a677 100644 +index 6c5d12d..d692a77 100644 --- a/server/thread.c +++ b/server/thread.c @@ -194,6 +194,8 @@ static inline void init_thread_structure( struct thread *thread ) @@ -419,5 +419,5 @@ index 996d95b..0107a45 100644 struct thread_snapshot -- -2.3.2 +2.3.7 diff --git a/patches/server-Shared_Memory/0009-user32-Cache-the-result-of-GetForegroundWindow.patch b/patches/server-Shared_Memory/0009-user32-Cache-the-result-of-GetForegroundWindow.patch index 82d83908..1736ef38 100644 --- a/patches/server-Shared_Memory/0009-user32-Cache-the-result-of-GetForegroundWindow.patch +++ b/patches/server-Shared_Memory/0009-user32-Cache-the-result-of-GetForegroundWindow.patch @@ -1,4 +1,4 @@ -From cb26dcfdc62218fd2064799771b5c02d79049dcb Mon Sep 17 00:00:00 2001 +From 8f5ab18e86ae4914f3a79e16f8317a8f297ac179 Mon Sep 17 00:00:00 2001 From: Sebastian Lackner Date: Sat, 21 Mar 2015 22:35:24 +0100 Subject: user32: Cache the result of GetForegroundWindow. @@ -7,8 +7,8 @@ Subject: user32: Cache the result of GetForegroundWindow. dlls/user32/focus.c | 21 ++++++++++++++++++++- dlls/user32/user_private.h | 2 ++ server/protocol.def | 5 ++++- - server/queue.c | 17 +++++++++++++++-- - 4 files changed, 41 insertions(+), 4 deletions(-) + server/queue.c | 20 ++++++++++++++++++-- + 4 files changed, 44 insertions(+), 4 deletions(-) diff --git a/dlls/user32/focus.c b/dlls/user32/focus.c index 35fe89b..8b17d1f 100644 @@ -61,7 +61,7 @@ index 1c87de4..26c771e 100644 C_ASSERT( sizeof(struct user_thread_info) <= sizeof(((TEB *)0)->Win32ClientInfo) ); diff --git a/server/protocol.def b/server/protocol.def -index 5ec2485..0e4d3d8 100644 +index 29c31da..a49d9d0 100644 --- a/server/protocol.def +++ b/server/protocol.def @@ -69,11 +69,14 @@ struct request_max_size @@ -81,10 +81,10 @@ index 5ec2485..0e4d3d8 100644 { int queue_bits; /* queue wake bits */ diff --git a/server/queue.c b/server/queue.c -index 33c2758..b770456 100644 +index 6bbd2f2..f430eef 100644 --- a/server/queue.c +++ b/server/queue.c -@@ -436,6 +436,7 @@ static void set_foreground_input( struct desktop *desktop, struct thread_input * +@@ -448,6 +448,7 @@ static void set_foreground_input( struct desktop *desktop, struct thread_input * if (desktop->foreground_input == input) return; set_clip_rectangle( desktop, NULL, 1 ); desktop->foreground_input = input; @@ -92,7 +92,7 @@ index 33c2758..b770456 100644 } /* get the hook table for a given thread */ -@@ -1076,7 +1077,12 @@ static inline void thread_input_cleanup_window( struct msg_queue *queue, user_ha +@@ -1093,7 +1094,12 @@ static inline void thread_input_cleanup_window( struct msg_queue *queue, user_ha if (window == input->focus) input->focus = 0; if (window == input->capture) input->capture = 0; @@ -106,7 +106,7 @@ index 33c2758..b770456 100644 if (window == input->menu_owner) input->menu_owner = 0; if (window == input->move_size) input->move_size = 0; if (window == input->caret) set_caret_window( input, 0 ); -@@ -1131,7 +1137,12 @@ int attach_thread_input( struct thread *thread_from, struct thread *thread_to ) +@@ -1148,7 +1154,12 @@ int attach_thread_input( struct thread *thread_from, struct thread *thread_to ) if (thread_from->queue) { if (!input->focus) input->focus = thread_from->queue->input->focus; @@ -120,7 +120,17 @@ index 33c2758..b770456 100644 } ret = assign_thread_input( thread_from, input ); -@@ -3028,6 +3039,8 @@ DECL_HANDLER(set_active_window) +@@ -1180,6 +1191,9 @@ void detach_thread_input( struct thread *thread_from ) + { + input->active = old_input->active; + old_input->active = 0; ++ if (shmglobal && (input->desktop->foreground_input == input || ++ old_input->desktop->foreground_input == old_input)) ++ interlocked_xchg_add( (int *)&shmglobal->foreground_wnd_epoch, 1 ); + } + release_object( thread ); + } +@@ -3070,6 +3084,8 @@ DECL_HANDLER(set_active_window) reply->previous = queue->input->active; queue->input->active = get_user_full_handle( req->handle ); update_shm_thread_input( queue->input ); @@ -130,5 +140,5 @@ index 33c2758..b770456 100644 else set_error( STATUS_INVALID_HANDLE ); } -- -2.3.5 +2.3.7 diff --git a/patches/wined3d-CSMT_Main/9999-IfDefined.patch b/patches/wined3d-CSMT_Main/9999-IfDefined.patch index 15052ef7..4a548cc6 100644 --- a/patches/wined3d-CSMT_Main/9999-IfDefined.patch +++ b/patches/wined3d-CSMT_Main/9999-IfDefined.patch @@ -8307,7 +8307,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c } static HRESULT ffp_blit_alloc(struct wined3d_device *device) { return WINED3D_OK; } -@@ -4179,6 +5368,7 @@ +@@ -4176,6 +5365,7 @@ const RECT *dst_rect, const struct wined3d_color *color) { const RECT draw_rect = {0, 0, dst_surface->resource.width, dst_surface->resource.height}; @@ -8315,7 +8315,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c struct wined3d_rendertarget_view view, *view_ptr = &view; struct wined3d_fb_state fb = {&view_ptr, NULL, 1}; struct wined3d_texture *texture = dst_surface->container; -@@ -4199,6 +5389,21 @@ +@@ -4196,6 +5386,21 @@ view.sub_resource_idx = dst_surface->texture_layer * texture->level_count + dst_surface->texture_level; device_clear_render_targets(device, 1, &fb, 1, dst_rect, &draw_rect, WINED3DCLEAR_TARGET, color, 0.0f, 0); @@ -8337,7 +8337,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c return WINED3D_OK; } -@@ -4207,6 +5412,7 @@ +@@ -4204,6 +5409,7 @@ const RECT *dst_rect, float depth) { const RECT draw_rect = {0, 0, dst_surface->resource.width, dst_surface->resource.height}; @@ -8345,7 +8345,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c struct wined3d_rendertarget_view view; struct wined3d_fb_state fb = {NULL, &view}; struct wined3d_texture *texture = dst_surface->container; -@@ -4222,6 +5428,20 @@ +@@ -4219,6 +5425,20 @@ view.sub_resource_idx = dst_surface->texture_layer * texture->level_count + dst_surface->texture_level; device_clear_render_targets(device, 0, &fb, 1, dst_rect, &draw_rect, WINED3DCLEAR_ZBUFFER, 0, depth, 0); @@ -8366,7 +8366,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c return WINED3D_OK; } -@@ -4234,6 +5454,7 @@ +@@ -4231,6 +5451,7 @@ /* Blit from offscreen surface to render target */ struct wined3d_color_key old_blt_key = src_surface->container->async.src_blt_color_key; DWORD old_color_key_flags = src_surface->container->async.color_key_flags; @@ -8374,7 +8374,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c struct wined3d_context *context; TRACE("Blt from surface %p to rendertarget %p\n", src_surface, dst_surface); -@@ -4251,6 +5472,22 @@ +@@ -4248,6 +5469,22 @@ wined3d_resource_validate_location(&dst_surface->resource, dst_surface->container->resource.draw_binding); wined3d_resource_invalidate_location(&dst_surface->resource, ~dst_surface->container->resource.draw_binding); @@ -8397,7 +8397,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c } const struct blit_shader ffp_blit = { -@@ -4410,6 +5647,7 @@ +@@ -4407,6 +5644,7 @@ const struct wined3d_format *src_format, *dst_format; unsigned int src_fmt_flags, dst_fmt_flags; struct wined3d_texture *src_texture = NULL; @@ -8405,7 +8405,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c void *src_data = NULL, *dst_data = NULL; UINT src_row_pitch, src_slice_pitch, dst_row_pitch, dst_slice_pitch; const BYTE *sbase = NULL; -@@ -4440,6 +5678,23 @@ +@@ -4437,6 +5675,23 @@ wined3d_resource_get_pitch(&dst_surface->resource, &dst_row_pitch, &dst_slice_pitch); src_data = dst_data; src_row_pitch = dst_row_pitch; @@ -8429,7 +8429,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c src_format = dst_surface->resource.format; dst_format = src_format; dst_fmt_flags = dst_surface->resource.format_flags; -@@ -4451,12 +5706,14 @@ +@@ -4448,12 +5703,14 @@ dst_fmt_flags = dst_surface->resource.format_flags; if (src_surface) { @@ -8444,7 +8444,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c if (dst_surface->resource.format->id != src_surface->resource.format->id) { if (!(src_texture = surface_convert_format(src_surface, dst_format->id))) -@@ -4467,9 +5724,13 @@ +@@ -4464,9 +5721,13 @@ } src_surface = surface_from_resource(wined3d_texture_get_sub_resource(src_texture, 0)); } @@ -8458,7 +8458,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c src_format = src_surface->resource.format; src_fmt_flags = src_surface->resource.format_flags; } -@@ -4479,8 +5740,12 @@ +@@ -4476,8 +5737,12 @@ src_fmt_flags = dst_fmt_flags; } @@ -8471,7 +8471,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c } bpp = dst_surface->resource.format->byte_count; -@@ -4491,12 +5756,24 @@ +@@ -4488,12 +5753,24 @@ width = (dst_rect->right - dst_rect->left) * bpp; if (src_surface) @@ -8496,7 +8496,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c if (src_fmt_flags & dst_fmt_flags & WINED3DFMT_FLAG_BLOCKS) { -@@ -4531,7 +5808,11 @@ +@@ -4528,7 +5805,11 @@ } hr = surface_cpu_blt_compressed(sbase, dbuf, @@ -8508,7 +8508,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c src_format, flags, fx); goto release; } -@@ -4539,7 +5820,11 @@ +@@ -4536,7 +5817,11 @@ /* First, all the 'source-less' blits */ if (flags & WINEDDBLT_COLORFILL) { @@ -8520,7 +8520,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c flags &= ~WINEDDBLT_COLORFILL; } -@@ -4588,6 +5873,7 @@ +@@ -4585,6 +5870,7 @@ for (y = 0; y < dstheight; ++y) { memcpy(dbuf, sbuf, width); @@ -8528,7 +8528,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c sbuf += src_row_pitch; dbuf += dst_row_pitch; } -@@ -4601,6 +5887,21 @@ +@@ -4598,6 +5884,21 @@ { sbuf -= src_row_pitch; dbuf -= dst_row_pitch; @@ -8550,7 +8550,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c memcpy(dbuf, sbuf, width); } } -@@ -4610,8 +5911,13 @@ +@@ -4607,8 +5908,13 @@ for (y = 0; y < dstheight; ++y) { memmove(dbuf, sbuf, width); @@ -8564,7 +8564,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c } } } -@@ -4620,9 +5926,15 @@ +@@ -4617,9 +5923,15 @@ /* Stretching in y direction only. */ for (y = sy = 0; y < dstheight; ++y, sy += yinc) { @@ -8580,7 +8580,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c } } } -@@ -4632,6 +5944,7 @@ +@@ -4629,6 +5941,7 @@ int last_sy = -1; for (y = sy = 0; y < dstheight; ++y, sy += yinc) { @@ -8588,7 +8588,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c sbuf = sbase + (sy >> 16) * src_row_pitch; if ((sy >> 16) == (last_sy >> 16)) -@@ -4639,6 +5952,15 @@ +@@ -4636,6 +5949,15 @@ /* This source row is the same as last source row - * Copy the already stretched row. */ memcpy(dbuf, dbuf - dst_row_pitch, width); @@ -8604,7 +8604,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c } else { -@@ -4685,6 +6007,7 @@ +@@ -4682,6 +6004,7 @@ } #undef STRETCH_ROW } @@ -8612,7 +8612,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c dbuf += dst_row_pitch; last_sy = sy; } -@@ -4693,6 +6016,16 @@ +@@ -4690,6 +6013,16 @@ else { LONG dstyinc = dst_row_pitch, dstxinc = bpp; @@ -8629,7 +8629,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c DWORD keylow = 0xffffffff, keyhigh = 0, keymask = 0xffffffff; DWORD destkeylow = 0x0, destkeyhigh = 0xffffffff, destkeymask = 0xffffffff; if (flags & (WINEDDBLT_KEYSRC | WINEDDBLT_KEYDEST | WINEDDBLT_KEYSRCOVERRIDE | WINEDDBLT_KEYDESTOVERRIDE)) -@@ -4742,7 +6075,11 @@ +@@ -4739,7 +6072,11 @@ LONG tmpxy; dTopLeft = dbuf; dTopRight = dbuf + ((dstwidth - 1) * bpp); @@ -8641,7 +8641,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c dBottomRight = dBottomLeft + ((dstwidth - 1) * bpp); if (fx->dwDDFX & WINEDDBLTFX_ARITHSTRETCHY) -@@ -4819,6 +6156,7 @@ +@@ -4816,6 +6153,7 @@ flags &= ~(WINEDDBLT_DDFX); } @@ -8649,7 +8649,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c #define COPY_COLORKEY_FX(type) \ do { \ const type *s; \ -@@ -4840,6 +6178,29 @@ +@@ -4837,6 +6175,29 @@ d = (type *)(((BYTE *)d) + dstyinc); \ } \ } while(0) @@ -8679,7 +8679,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c switch (bpp) { -@@ -4858,7 +6219,11 @@ +@@ -4855,7 +6216,11 @@ BYTE *d = dbuf, *dx; for (y = sy = 0; y < dstheight; ++y, sy += yinc) { @@ -8691,7 +8691,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c dx = d; for (x = sx = 0; x < dstwidth; ++x, sx+= xinc) { -@@ -4889,10 +6254,12 @@ +@@ -4886,10 +6251,12 @@ } } @@ -8704,7 +8704,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c error: if (flags && FIXME_ON(d3d_surface)) { -@@ -4900,6 +6267,7 @@ +@@ -4897,6 +6264,7 @@ } release: @@ -8712,7 +8712,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c if (dst_data) { wined3d_resource_release_map_ptr(&dst_surface->resource, context); -@@ -4918,6 +6286,14 @@ +@@ -4915,6 +6283,14 @@ wined3d_texture_decref(src_texture); if (context) context_release(context); @@ -8727,7 +8727,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c return hr; } -@@ -4962,6 +6338,7 @@ +@@ -4959,6 +6335,7 @@ cpu_blit_blit_surface, }; @@ -8735,7 +8735,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c void surface_blt_ugly(struct wined3d_surface *dst_surface, const RECT *dst_rect, struct wined3d_surface *src_surface, const RECT *src_rect, DWORD flags, const WINEDDBLTFX *fx, enum wined3d_texture_filter_type filter) -@@ -4969,6 +6346,16 @@ +@@ -4966,6 +6343,16 @@ struct wined3d_swapchain *src_swapchain, *dst_swapchain; struct wined3d_device *device = dst_surface->resource.device; DWORD src_ds_flags, dst_ds_flags; @@ -8752,7 +8752,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c BOOL scale, convert; static const DWORD simple_blit = WINEDDBLT_ASYNC -@@ -4979,6 +6366,106 @@ +@@ -4976,6 +6363,106 @@ | WINEDDBLT_DEPTHFILL | WINEDDBLT_DONOTWAIT; @@ -8859,7 +8859,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c if (!device->d3d_initialized) { WARN("D3D not initialized, using fallback.\n"); -@@ -5021,8 +6508,13 @@ +@@ -5018,8 +6505,13 @@ } scale = src_surface @@ -8873,7 +8873,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c convert = src_surface && src_surface->resource.format->id != dst_surface->resource.format->id; dst_ds_flags = dst_surface->resource.format_flags & (WINED3DFMT_FLAG_DEPTH | WINED3DFMT_FLAG_STENCIL); -@@ -5040,6 +6532,7 @@ +@@ -5037,6 +6529,7 @@ TRACE("Depth fill.\n"); if (!surface_convert_depth_to_float(dst_surface, fx->u5.dwFillDepth, &depth)) @@ -8881,7 +8881,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c return; if (SUCCEEDED(wined3d_surface_depth_fill(dst_surface, dst_rect, depth))) -@@ -5050,6 +6543,24 @@ +@@ -5047,6 +6540,24 @@ if (SUCCEEDED(wined3d_surface_depth_blt(src_surface, src_surface->container->resource.draw_binding, src_rect, dst_surface, dst_surface->container->resource.draw_binding, dst_rect))) return; @@ -8906,7 +8906,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c } } else -@@ -5058,8 +6569,13 @@ +@@ -5055,8 +6566,13 @@ /* In principle this would apply to depth blits as well, but we don't * implement those in the CPU blitter at the moment. */ @@ -8920,7 +8920,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c { if (scale) TRACE("Not doing sysmem blit because of scaling.\n"); -@@ -5080,8 +6596,13 @@ +@@ -5077,8 +6593,13 @@ palette, fx->u5.dwFillColor, &color)) goto fallback; @@ -8934,7 +8934,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c } else { -@@ -5099,8 +6620,13 @@ +@@ -5096,8 +6617,13 @@ color_key = &src_surface->container->async.src_blt_color_key; blit_op = WINED3D_BLIT_OP_COLOR_BLIT_CKEY; } @@ -8948,7 +8948,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c { /* Upload */ if (scale) -@@ -5109,6 +6635,7 @@ +@@ -5106,6 +6632,7 @@ TRACE("Not doing upload because of format conversion.\n"); else { @@ -8956,7 +8956,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c POINT dst_point = {dst_rect->left, dst_rect->top}; if (SUCCEEDED(surface_upload_from_surface(dst_surface, &dst_point, src_surface, src_rect))) -@@ -5121,6 +6648,15 @@ +@@ -5118,6 +6645,15 @@ context_release(context); } return; @@ -8972,7 +8972,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c } } } -@@ -5144,6 +6680,7 @@ +@@ -5141,6 +6677,7 @@ wined3d_swapchain_present(dst_swapchain, NULL, NULL, dst_swapchain->win_handle, NULL, 0); dst_swapchain->desc.swap_effect = swap_effect; @@ -8980,7 +8980,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c return; } -@@ -5339,6 +6876,49 @@ +@@ -5336,6 +6873,49 @@ wined3d_surface_location_invalidated, wined3d_surface_load_location, }; @@ -9030,7 +9030,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c static HRESULT surface_init(struct wined3d_surface *surface, struct wined3d_texture *container, const struct wined3d_resource_desc *desc, GLenum target, unsigned int level, unsigned int layer, DWORD flags) -@@ -5406,7 +6986,11 @@ +@@ -5403,7 +6983,11 @@ } surface->container = container; @@ -9042,7 +9042,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c list_init(&surface->renderbuffers); list_init(&surface->overlays); -@@ -5438,9 +7022,14 @@ +@@ -5435,9 +7019,14 @@ if (surface->resource.map_binding == WINED3D_LOCATION_DIB) { wined3d_resource_free_sysmem(&surface->resource); @@ -9057,7 +9057,7 @@ diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c } return hr; -@@ -5467,7 +7056,11 @@ +@@ -5464,7 +7053,11 @@ if (FAILED(hr = surface_init(object, container, desc, target, level, layer, flags))) { WARN("Failed to initialize surface, returning %#x.\n", hr); diff --git a/patches/ws2_32-TransmitFile/0007-ws2_32-Add-support-for-TF_REUSE_SOCKET-to-TransmitFi.patch b/patches/ws2_32-TransmitFile/0007-ws2_32-Add-support-for-TF_REUSE_SOCKET-to-TransmitFi.patch index 026ac7fe..8d6f361c 100644 --- a/patches/ws2_32-TransmitFile/0007-ws2_32-Add-support-for-TF_REUSE_SOCKET-to-TransmitFi.patch +++ b/patches/ws2_32-TransmitFile/0007-ws2_32-Add-support-for-TF_REUSE_SOCKET-to-TransmitFi.patch @@ -1,4 +1,4 @@ -From c3dd4a094fe7ab0c3cd3934c4e30ce228e24aeb3 Mon Sep 17 00:00:00 2001 +From 0b55083552779d1148c04778f5479e5fc4e6d6e4 Mon Sep 17 00:00:00 2001 From: "Erich E. Hoover" Date: Thu, 16 Jan 2014 19:08:30 -0700 Subject: ws2_32: Add support for TF_REUSE_SOCKET to TransmitFile. @@ -12,10 +12,10 @@ Subject: ws2_32: Add support for TF_REUSE_SOCKET to TransmitFile. 5 files changed, 75 insertions(+), 11 deletions(-) diff --git a/dlls/ws2_32/socket.c b/dlls/ws2_32/socket.c -index 5c4a183..a29bcaa 100644 +index f530a94..bf33e25 100644 --- a/dlls/ws2_32/socket.c +++ b/dlls/ws2_32/socket.c -@@ -2645,6 +2645,17 @@ static NTSTATUS WS2_transmitfile_base( int fd, struct ws2_transmitfile_async *ws +@@ -2810,6 +2810,17 @@ static NTSTATUS WS2_transmitfile_base( int fd, struct ws2_transmitfile_async *ws if (status != STATUS_SUCCESS) return status; @@ -33,7 +33,7 @@ index 5c4a183..a29bcaa 100644 if (wsa->flags & TF_DISCONNECT) { /* we can't use WS_closesocket because it modifies the last error */ -@@ -2690,7 +2701,7 @@ static BOOL WINAPI WS2_TransmitFile( SOCKET s, HANDLE h, DWORD file_bytes, DWORD +@@ -2853,7 +2864,7 @@ static BOOL WINAPI WS2_TransmitFile( SOCKET s, HANDLE h, DWORD file_bytes, DWORD LPOVERLAPPED overlapped, LPTRANSMIT_FILE_BUFFERS buffers, DWORD flags ) { @@ -43,10 +43,10 @@ index 5c4a183..a29bcaa 100644 union generic_unix_sockaddr uaddr; unsigned int uaddrlen = sizeof(uaddr); diff --git a/dlls/ws2_32/tests/sock.c b/dlls/ws2_32/tests/sock.c -index 36920a7..3fc8599 100644 +index a8abdee..58d8db7 100644 --- a/dlls/ws2_32/tests/sock.c +++ b/dlls/ws2_32/tests/sock.c -@@ -7153,7 +7153,6 @@ static void test_TransmitFile(void) +@@ -7566,7 +7566,6 @@ static void test_TransmitFile(void) err, WSAENOTSOCK); /* Test TransmitFile with a UDP datagram socket */ @@ -67,10 +67,10 @@ index 50237e8..e53aa1e 100644 #define FD_WINE_NONBLOCKING 0x20000000 #define FD_WINE_CONNECTED 0x40000000 diff --git a/server/protocol.def b/server/protocol.def -index 7ec380b..e76bcb1 100644 +index 9c4dab4..0694f99 100644 --- a/server/protocol.def +++ b/server/protocol.def -@@ -1209,6 +1209,12 @@ enum server_fd_type +@@ -1230,6 +1230,12 @@ enum server_fd_type @END @@ -84,7 +84,7 @@ index 7ec380b..e76bcb1 100644 @REQ(set_socket_event) obj_handle_t handle; /* handle to the socket */ diff --git a/server/sock.c b/server/sock.c -index f3bab85..46bd2f7 100644 +index c4dcf6f..fb80bc7 100644 --- a/server/sock.c +++ b/server/sock.c @@ -86,6 +86,7 @@ @@ -95,15 +95,15 @@ index f3bab85..46bd2f7 100644 #define FD_WINE_LISTENING 0x10000000 #define FD_WINE_NONBLOCKING 0x20000000 #define FD_WINE_CONNECTED 0x40000000 -@@ -135,6 +136,7 @@ static obj_handle_t sock_ioctl( struct fd *fd, ioctl_code_t code, const async_da +@@ -134,6 +135,7 @@ static obj_handle_t sock_ioctl( struct fd *fd, ioctl_code_t code, const async_da static void sock_queue_async( struct fd *fd, const async_data_t *data, int type, int count ); static void sock_reselect_async( struct fd *fd, struct async_queue *queue ); - static void sock_cancel_async( struct fd *fd, struct process *process, struct thread *thread, client_ptr_t iosb ); + static int sock_cancel_async( struct fd *fd, struct process *process, struct thread *thread, client_ptr_t iosb ); +static int sock_close_handle( struct object *obj, struct process *process, obj_handle_t handle ); static int sock_get_ntstatus( int err ); static int sock_get_error( int err ); -@@ -156,7 +158,7 @@ static const struct object_ops sock_ops = +@@ -155,7 +157,7 @@ static const struct object_ops sock_ops = default_set_sd, /* set_sd */ no_lookup_name, /* lookup_name */ no_open_file, /* open_file */ @@ -112,7 +112,7 @@ index f3bab85..46bd2f7 100644 sock_destroy /* destroy */ }; -@@ -627,6 +629,47 @@ static struct fd *sock_get_fd( struct object *obj ) +@@ -628,6 +630,47 @@ static struct fd *sock_get_fd( struct object *obj ) return (struct fd *)grab_object( sock->fd ); } @@ -160,7 +160,7 @@ index f3bab85..46bd2f7 100644 static void sock_destroy( struct object *obj ) { struct sock *sock = (struct sock *)obj; -@@ -678,15 +721,8 @@ static struct object *create_socket( int family, int type, int protocol, unsigne +@@ -679,15 +722,8 @@ static struct object *create_socket( int family, int type, int protocol, unsigne struct sock *sock; int sockfd; @@ -177,7 +177,7 @@ index f3bab85..46bd2f7 100644 if (!(sock = alloc_object( &sock_ops ))) { close( sockfd ); -@@ -1282,6 +1318,17 @@ DECL_HANDLER(accept_into_socket) +@@ -1286,6 +1322,17 @@ DECL_HANDLER(accept_into_socket) release_object( sock ); } @@ -196,5 +196,5 @@ index f3bab85..46bd2f7 100644 DECL_HANDLER(set_socket_event) { -- -2.3.0 +2.3.7