winehq.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2025
February
January
2024
December
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
October
September
August
July
June
May
April
March
February
January
2007
December
November
October
September
August
July
June
May
April
March
February
January
2006
December
November
October
September
August
July
June
May
April
March
February
January
2005
December
November
October
September
August
July
June
May
April
March
February
January
2004
December
November
October
September
August
July
June
May
April
March
February
January
2003
December
November
October
September
August
July
June
May
April
March
February
January
2002
December
November
October
September
August
July
June
May
April
March
February
January
2001
December
November
October
September
August
July
June
May
April
March
February
List overview
wine-commits
August 2018
----- 2025 -----
February 2025
January 2025
----- 2024 -----
December 2024
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
April 2008
March 2008
February 2008
January 2008
----- 2007 -----
December 2007
November 2007
October 2007
September 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
----- 2006 -----
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
----- 2005 -----
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
----- 2004 -----
December 2004
November 2004
October 2004
September 2004
August 2004
July 2004
June 2004
May 2004
April 2004
March 2004
February 2004
January 2004
----- 2003 -----
December 2003
November 2003
October 2003
September 2003
August 2003
July 2003
June 2003
May 2003
April 2003
March 2003
February 2003
January 2003
----- 2002 -----
December 2002
November 2002
October 2002
September 2002
August 2002
July 2002
June 2002
May 2002
April 2002
March 2002
February 2002
January 2002
----- 2001 -----
December 2001
November 2001
October 2001
September 2001
August 2001
July 2001
June 2001
May 2001
April 2001
March 2001
February 2001
wine-commits@winehq.org
2 participants
618 discussions
Start a n
N
ew thread
Nikolay Sivov : winecfg: Update changed state on associations checkbox click.
by Alexandre Julliard
17 Aug '18
17 Aug '18
Module: wine Branch: master Commit: 25ba7708d3ad01202d1fd59633f0829360c0b4c4 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=25ba7708d3ad01202d1fd596…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Fri Aug 17 00:31:56 2018 +0300 winecfg: Update changed state on associations checkbox click. Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- programs/winecfg/theme.c | 1 + 1 file changed, 1 insertion(+) diff --git a/programs/winecfg/theme.c b/programs/winecfg/theme.c index 1934538..5304f72 100644 --- a/programs/winecfg/theme.c +++ b/programs/winecfg/theme.c @@ -1320,6 +1320,7 @@ ThemeDlgProc (HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam) case IDC_ENABLE_FILE_ASSOCIATIONS: update_mime_types(hDlg); + SendMessageW(GetParent(hDlg), PSM_CHANGED, 0, 0); break; } break;
1
0
0
0
Alex Henrie : shell32: Add document icon.
by Alexandre Julliard
17 Aug '18
17 Aug '18
Module: wine Branch: master Commit: b14d8f9f11856c1b1f192bf773eb864cba5ad78b URL:
https://source.winehq.org/git/wine.git/?a=commit;h=b14d8f9f11856c1b1f192bf7…
Author: Alex Henrie <alexhenrie24(a)gmail.com> Date: Tue Aug 14 22:09:57 2018 -0600 shell32: Add document icon. Signed-off-by: Alex Henrie <alexhenrie24(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/shell32/shell32.rc | 3 +++ dlls/shell32/shresdef.h | 1 + 2 files changed, 4 insertions(+) diff --git a/dlls/shell32/shell32.rc b/dlls/shell32/shell32.rc index 992c70f..b6cae77 100644 --- a/dlls/shell32/shell32.rc +++ b/dlls/shell32/shell32.rc @@ -422,6 +422,9 @@ END /* @makedep: document.ico */ IDI_SHELL_FILE ICON document.ico +/* @makedep: document.ico */ +IDI_SHELL_DOCUMENT ICON document.ico + /* @makedep: folder.ico */ IDI_SHELL_FOLDER ICON folder.ico diff --git a/dlls/shell32/shresdef.h b/dlls/shell32/shresdef.h index cf43d4a..9c46d5f 100644 --- a/dlls/shell32/shresdef.h +++ b/dlls/shell32/shresdef.h @@ -170,6 +170,7 @@ #define IDD_TREEVIEW 0x3741 #define IDI_SHELL_FILE 1 +#define IDI_SHELL_DOCUMENT 2 #define IDI_SHELL_FOLDER 4 #define IDI_SHELL_FOLDER_OPEN 5 #define IDI_SHELL_5_12_FLOPPY 6
1
0
0
0
Alex Henrie : shell32: Rename IDI_SHELL_DOCUMENT to IDI_SHELL_FILE.
by Alexandre Julliard
17 Aug '18
17 Aug '18
Module: wine Branch: master Commit: 4b5d0f2f43ad1d34b1e3fb4424615c918487e68c URL:
https://source.winehq.org/git/wine.git/?a=commit;h=4b5d0f2f43ad1d34b1e3fb44…
Author: Alex Henrie <alexhenrie24(a)gmail.com> Date: Tue Aug 14 22:09:56 2018 -0600 shell32: Rename IDI_SHELL_DOCUMENT to IDI_SHELL_FILE. Signed-off-by: Alex Henrie <alexhenrie24(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/shell32/iconcache.c | 12 ++++++------ dlls/shell32/shell32.rc | 3 ++- dlls/shell32/shresdef.h | 2 +- 3 files changed, 9 insertions(+), 8 deletions(-) diff --git a/dlls/shell32/iconcache.c b/dlls/shell32/iconcache.c index d55bde9..6107e0c 100644 --- a/dlls/shell32/iconcache.c +++ b/dlls/shell32/iconcache.c @@ -467,8 +467,8 @@ static BOOL WINAPI SIC_Initialize( INIT_ONCE *once, void *param, void **context shell_imagelists[i] = ImageList_Create(sizes[i].cx, sizes[i].cy, ILC_COLOR32 | ILC_MASK, 0, 0x20); ImageList_SetBkColor(shell_imagelists[i], CLR_NONE); - /* Load the document icon, which is used as the default if an icon isn't found. */ - if (!(hicons[i] = LoadImageA(shell32_hInstance, MAKEINTRESOURCEA(IDI_SHELL_DOCUMENT), + /* Load the generic file icon, which is used as the default if an icon isn't found. */ + if (!(hicons[i] = LoadImageA(shell32_hInstance, MAKEINTRESOURCEA(IDI_SHELL_FILE), IMAGE_ICON, sizes[i].cx, sizes[i].cy, LR_SHARED))) { failed = TRUE; @@ -477,12 +477,12 @@ static BOOL WINAPI SIC_Initialize( INIT_ONCE *once, void *param, void **context if (failed) { - FIXME("Failed to load IDI_SHELL_DOCUMENT icon!\n"); + FIXME("Failed to load IDI_SHELL_FILE icon!\n"); return FALSE; } - SIC_IconAppend(swShell32Name, IDI_SHELL_DOCUMENT - 1, hicons, 0); - SIC_IconAppend(swShell32Name, -IDI_SHELL_DOCUMENT, hicons, 0); + SIC_IconAppend(swShell32Name, IDI_SHELL_FILE - 1, hicons, 0); + SIC_IconAppend(swShell32Name, -IDI_SHELL_FILE, hicons, 0); TRACE("small list=%p, large list=%p\n", shell_imagelists[SHIL_SMALL], shell_imagelists[SHIL_LARGE]); @@ -1014,7 +1014,7 @@ HRESULT WINAPI SHGetStockIconInfo(SHSTOCKICONID id, UINT flags, SHSTOCKICONINFO GetSystemDirectoryW(sii->szPath, MAX_PATH); /* no icons defined: use default */ - sii->iIcon = -IDI_SHELL_DOCUMENT; + sii->iIcon = -IDI_SHELL_FILE; lstrcatW(sii->szPath, shell32dll); if (flags) diff --git a/dlls/shell32/shell32.rc b/dlls/shell32/shell32.rc index 084b052..992c70f 100644 --- a/dlls/shell32/shell32.rc +++ b/dlls/shell32/shell32.rc @@ -418,8 +418,9 @@ BEGIN VK_F5, FCIDM_SHVIEW_REFRESH, VIRTKEY END +/* FIXME: Following resource is not yet added */ /* @makedep: document.ico */ -IDI_SHELL_DOCUMENT ICON document.ico +IDI_SHELL_FILE ICON document.ico /* @makedep: folder.ico */ IDI_SHELL_FOLDER ICON folder.ico diff --git a/dlls/shell32/shresdef.h b/dlls/shell32/shresdef.h index 1518de5..cf43d4a 100644 --- a/dlls/shell32/shresdef.h +++ b/dlls/shell32/shresdef.h @@ -169,7 +169,7 @@ #define IDD_TITLE 0x3742 #define IDD_TREEVIEW 0x3741 -#define IDI_SHELL_DOCUMENT 1 +#define IDI_SHELL_FILE 1 #define IDI_SHELL_FOLDER 4 #define IDI_SHELL_FOLDER_OPEN 5 #define IDI_SHELL_5_12_FLOPPY 6
1
0
0
0
Michael Stefaniuc : wineandroid.drv: Use the ARRAY_SIZE() macro.
by Alexandre Julliard
16 Aug '18
16 Aug '18
Module: wine Branch: master Commit: ccf6211c0ae6e86218f7e6c1f2fe725a23e568b9 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=ccf6211c0ae6e86218f7e6c1…
Author: Michael Stefaniuc <mstefani(a)winehq.org> Date: Thu Aug 16 20:19:30 2018 +0200 wineandroid.drv: Use the ARRAY_SIZE() macro. Signed-off-by: Michael Stefaniuc <mstefani(a)winehq.org> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/wineandroid.drv/device.c | 4 ++-- dlls/wineandroid.drv/init.c | 2 +- dlls/wineandroid.drv/keyboard.c | 10 +++++----- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/dlls/wineandroid.drv/device.c b/dlls/wineandroid.drv/device.c index 0ccae11..20519e2 100644 --- a/dlls/wineandroid.drv/device.c +++ b/dlls/wineandroid.drv/device.c @@ -1363,7 +1363,7 @@ static int perform( ANativeWindow *window, int operation, ... ) case NATIVE_WINDOW_SET_POST_TRANSFORM_CROP: default: FIXME( "unsupported perform hwnd %p op %d %s\n", win->hwnd, operation, - operation < sizeof(names)/sizeof(names[0]) ? names[operation] : "???" ); + operation < ARRAY_SIZE( names ) ? names[operation] : "???" ); break; } va_end( args ); @@ -1419,7 +1419,7 @@ void release_ioctl_window( struct ANativeWindow *window ) if (InterlockedDecrement( &win->ref ) > 0) return; TRACE( "%p %p\n", win, win->hwnd ); - for (i = 0; i < sizeof(win->buffers)/sizeof(win->buffers[0]); i++) + for (i = 0; i < ARRAY_SIZE( win->buffers ); i++) if (win->buffers[i]) win->buffers[i]->buffer.common.decRef( &win->buffers[i]->buffer.common ); destroy_ioctl_window( win->hwnd, win->opengl ); diff --git a/dlls/wineandroid.drv/init.c b/dlls/wineandroid.drv/init.c index 0dd3e5e..da8fba3 100644 --- a/dlls/wineandroid.drv/init.c +++ b/dlls/wineandroid.drv/init.c @@ -677,7 +677,7 @@ static BOOL process_attach(void) load_android_libs(); (*java_vm)->AttachCurrentThread( java_vm, &jni_env, 0 ); class = (*jni_env)->GetObjectClass( jni_env, object ); - (*jni_env)->RegisterNatives( jni_env, class, methods, sizeof(methods)/sizeof(methods[0]) ); + (*jni_env)->RegisterNatives( jni_env, class, methods, ARRAY_SIZE( methods )); (*jni_env)->DeleteLocalRef( jni_env, class ); #ifdef __i386__ wine_set_fs( old_fs ); /* the Java VM hijacks %fs for its own purposes, restore it */ diff --git a/dlls/wineandroid.drv/keyboard.c b/dlls/wineandroid.drv/keyboard.c index 3167d54..2c37c42 100644 --- a/dlls/wineandroid.drv/keyboard.c +++ b/dlls/wineandroid.drv/keyboard.c @@ -638,7 +638,7 @@ static UINT scancode_to_vkey( UINT scan ) { UINT j; - for (j = 0; j < sizeof(vkey_to_scancode)/sizeof(vkey_to_scancode[0]); j++) + for (j = 0; j < ARRAY_SIZE( vkey_to_scancode ); j++) if (vkey_to_scancode[j] == scan) return j; return 0; @@ -648,7 +648,7 @@ static const char* vkey_to_name( UINT vkey ) { UINT j; - for (j = 0; j < sizeof(vkey_names)/sizeof(vkey_names[0]); j++) + for (j = 0; j < ARRAY_SIZE( vkey_names ); j++) if (vkey_names[j].vkey == vkey) return vkey_names[j].name; return NULL; @@ -724,7 +724,7 @@ jboolean keyboard_event( JNIEnv *env, jobject obj, jint win, jint action, jint k { union event_data data; - if ((unsigned int)keycode >= sizeof(keycode_to_vkey)/sizeof(keycode_to_vkey[0]) || + if ((unsigned int)keycode >= ARRAY_SIZE( keycode_to_vkey ) || !keycode_to_vkey[keycode]) { p__android_log_print( ANDROID_LOG_WARN, "wine", @@ -931,7 +931,7 @@ UINT CDECL ANDROID_MapVirtualKeyEx( UINT code, UINT maptype, HKL hkl ) code = VK_LMENU; break; } - if (code < sizeof(vkey_to_scancode) / sizeof(vkey_to_scancode[0])) ret = vkey_to_scancode[code]; + if (code < ARRAY_SIZE( vkey_to_scancode )) ret = vkey_to_scancode[code]; break; case MAPVK_VSC_TO_VK: case MAPVK_VSC_TO_VK_EX: @@ -993,7 +993,7 @@ HKL CDECL ANDROID_GetKeyboardLayout( DWORD thread_id ) SHORT CDECL ANDROID_VkKeyScanEx( WCHAR ch, HKL hkl ) { SHORT ret = -1; - if (ch < sizeof(char_vkey_map) / sizeof(char_vkey_map[0])) ret = char_vkey_map[ch]; + if (ch < ARRAY_SIZE( char_vkey_map )) ret = char_vkey_map[ch]; TRACE_(key)( "ch %04x hkl %p -> %04x\n", ch, hkl, ret ); return ret; }
1
0
0
0
Michael Stefaniuc : ieframe: Use the ARRAY_SIZE() macro.
by Alexandre Julliard
16 Aug '18
16 Aug '18
Module: wine Branch: master Commit: 5e96cd7244f686433017bfb0df1f9387e0276f54 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=5e96cd7244f686433017bfb0…
Author: Michael Stefaniuc <mstefani(a)winehq.org> Date: Thu Aug 16 20:19:29 2018 +0200 ieframe: Use the ARRAY_SIZE() macro. Signed-off-by: Michael Stefaniuc <mstefani(a)winehq.org> Signed-off-by: Jacek Caban <jacek(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/ieframe/dochost.c | 2 +- dlls/ieframe/ieframe_main.c | 2 +- dlls/ieframe/iexplore.c | 10 +++++----- dlls/ieframe/intshcut.c | 4 ++-- dlls/ieframe/navigate.c | 10 +++++----- dlls/ieframe/oleobject.c | 2 +- dlls/ieframe/shellbrowser.c | 2 +- 7 files changed, 16 insertions(+), 16 deletions(-) diff --git a/dlls/ieframe/dochost.c b/dlls/ieframe/dochost.c index 424868d..d22ad3d 100644 --- a/dlls/ieframe/dochost.c +++ b/dlls/ieframe/dochost.c @@ -428,7 +428,7 @@ static void update_travellog(DocHost *This) static const WCHAR about_schemeW[] = {'a','b','o','u','t',':'}; - if(This->url && !strncmpiW(This->url, about_schemeW, sizeof(about_schemeW)/sizeof(*about_schemeW))) { + if(This->url && !strncmpiW(This->url, about_schemeW, ARRAY_SIZE(about_schemeW))) { TRACE("Skipping about URL\n"); return; } diff --git a/dlls/ieframe/ieframe_main.c b/dlls/ieframe/ieframe_main.c index a862f9a..e207ce0 100644 --- a/dlls/ieframe/ieframe_main.c +++ b/dlls/ieframe/ieframe_main.c @@ -91,7 +91,7 @@ static void release_typelib(void) if(!typelib) return; - for(i=0; i < sizeof(typeinfos)/sizeof(*typeinfos); i++) { + for(i=0; i < ARRAY_SIZE(typeinfos); i++) { if(typeinfos[i]) ITypeInfo_Release(typeinfos[i]); } diff --git a/dlls/ieframe/iexplore.c b/dlls/ieframe/iexplore.c index aac1436..1a83ee3 100644 --- a/dlls/ieframe/iexplore.c +++ b/dlls/ieframe/iexplore.c @@ -263,7 +263,7 @@ static void add_tbs_to_menu(HMENU menu) WCHAR classes_key[] = {'S','o','f','t','w','a','r','e','\\', 'C','l','a','s','s','e','s','\\','C','L','S','I','D',0}; WCHAR guid[39]; - DWORD value_len = sizeof(guid)/sizeof(guid[0]); + DWORD value_len = ARRAY_SIZE(guid); int i; if(SHRegOpenUSKeyW(classes_key, KEY_READ, NULL, &classes_handle, TRUE) != ERROR_SUCCESS) @@ -276,11 +276,11 @@ static void add_tbs_to_menu(HMENU menu) for(i = 0; SHRegEnumUSValueW(toolbar_handle, i, guid, &value_len, NULL, NULL, NULL, SHREGENUM_HKLM) == ERROR_SUCCESS; i++) { WCHAR tb_name[100]; - DWORD tb_name_len = sizeof(tb_name)/sizeof(tb_name[0]); + DWORD tb_name_len = ARRAY_SIZE(tb_name); HUSKEY tb_class_handle; MENUITEMINFOW item; LSTATUS ret; - value_len = sizeof(guid)/sizeof(guid[0]); + value_len = ARRAY_SIZE(guid); if(lstrlenW(guid) != 38) { @@ -418,7 +418,7 @@ static void add_tb_button(InternetExplorer *ie, int bmp, int cmd, int strId) TBBUTTON btn; WCHAR buf[30]; - LoadStringW(ieframe_instance, strId, buf, sizeof(buf)/sizeof(buf[0])); + LoadStringW(ieframe_instance, strId, buf, ARRAY_SIZE(buf)); btn.iBitmap = bmp; btn.idCommand = cmd; @@ -445,7 +445,7 @@ static void create_rebar(InternetExplorer *ie) HIMAGELIST imagelist; SIZE toolbar_size; - LoadStringW(ieframe_instance, IDS_ADDRESS, addr, sizeof(addr)/sizeof(addr[0])); + LoadStringW(ieframe_instance, IDS_ADDRESS, addr, ARRAY_SIZE(addr)); hwndRebar = CreateWindowExW(WS_EX_TOOLWINDOW, REBARCLASSNAMEW, NULL, WS_CHILD|WS_VISIBLE|WS_CLIPSIBLINGS|WS_CLIPCHILDREN|RBS_VARHEIGHT|CCS_TOP|CCS_NODIVIDER, 0, 0, 0, 0, diff --git a/dlls/ieframe/intshcut.c b/dlls/ieframe/intshcut.c index 2376b1b..4331bb9 100644 --- a/dlls/ieframe/intshcut.c +++ b/dlls/ieframe/intshcut.c @@ -93,7 +93,7 @@ static BOOL run_winemenubuilder( const WCHAR *args ) WCHAR app[MAX_PATH]; void *redir; - GetSystemDirectoryW( app, MAX_PATH - sizeof(menubuilder)/sizeof(WCHAR) ); + GetSystemDirectoryW( app, MAX_PATH - ARRAY_SIZE( menubuilder )); strcatW( app, menubuilder ); len = (strlenW( app ) + strlenW( args ) + 1) * sizeof(WCHAR); @@ -278,7 +278,7 @@ static HRESULT WINAPI UniformResourceLocatorW_InvokeCommand(IUniformResourceLoca return E_NOTIMPL; } - hres = CoInternetParseUrl(This->url, PARSE_SCHEMA, 0, app, sizeof(app)/sizeof(WCHAR), NULL, 0); + hres = CoInternetParseUrl(This->url, PARSE_SCHEMA, 0, app, ARRAY_SIZE(app), NULL, 0); if(FAILED(hres)) return E_FAIL; diff --git a/dlls/ieframe/navigate.c b/dlls/ieframe/navigate.c index 658857f..96fb083 100644 --- a/dlls/ieframe/navigate.c +++ b/dlls/ieframe/navigate.c @@ -111,7 +111,7 @@ static void set_status_text(BindStatusCallback *This, ULONG statuscode, LPCWSTR fmt[0] = 0; /* the format string must have one "%s" for the str */ LoadStringW(ieframe_instance, IDS_STATUSFMT_FIRST + statuscode, fmt, IDS_STATUSFMT_MAXLEN); - snprintfW(buffer, sizeof(buffer)/sizeof(WCHAR), fmt, str); + snprintfW(buffer, ARRAY_SIZE(buffer), fmt, str); } V_VT(&arg) = VT_BSTR; @@ -576,7 +576,7 @@ static void on_before_navigate2(DocHost *This, LPCWSTR url, SAFEARRAY *post_data DISPPARAMS dispparams; VARIANTARG params[7]; WCHAR file_path[MAX_PATH]; - DWORD file_path_len = sizeof(file_path) / sizeof(*file_path); + DWORD file_path_len = ARRAY_SIZE(file_path); dispparams.cArgs = 7; dispparams.cNamedArgs = 0; @@ -642,7 +642,7 @@ static BOOL try_application_url(LPCWSTR url) static const WCHAR wszURLProtocol[] = {'U','R','L',' ','P','r','o','t','o','c','o','l',0}; - hres = CoInternetParseUrl(url, PARSE_SCHEMA, 0, app, sizeof(app)/sizeof(WCHAR), NULL, 0); + hres = CoInternetParseUrl(url, PARSE_SCHEMA, 0, app, ARRAY_SIZE(app), NULL, 0); if(FAILED(hres)) return FALSE; @@ -674,7 +674,7 @@ static HRESULT create_moniker(LPCWSTR url, IMoniker **mon) if(PathIsURLW(url)) return CreateURLMoniker(NULL, url, mon); - size = sizeof(new_url)/sizeof(WCHAR); + size = ARRAY_SIZE(new_url); hres = UrlApplySchemeW(url, new_url, &size, URL_APPLY_GUESSSCHEME | URL_APPLY_GUESSFILE | URL_APPLY_DEFAULT); TRACE("was %s got %s\n", debugstr_w(url), debugstr_w(new_url)); if(FAILED(hres)) { @@ -978,7 +978,7 @@ HRESULT navigate_url(DocHost *This, LPCWSTR url, const VARIANT *Flags, }else { DWORD size; - size = sizeof(new_url)/sizeof(WCHAR); + size = ARRAY_SIZE(new_url); hres = UrlApplySchemeW(url, new_url, &size, URL_APPLY_GUESSSCHEME | URL_APPLY_GUESSFILE | URL_APPLY_DEFAULT); if(FAILED(hres)) { diff --git a/dlls/ieframe/oleobject.c b/dlls/ieframe/oleobject.c index 1ff9a92..22fe4b1 100644 --- a/dlls/ieframe/oleobject.c +++ b/dlls/ieframe/oleobject.c @@ -385,7 +385,7 @@ static HRESULT WINAPI EnumOLEVERB_Next(IEnumOLEVERB *iface, ULONG celt, OLEVERB if(pceltFetched) *pceltFetched = 0; - if(This->iter == sizeof(verbs)/sizeof(*verbs)) + if(This->iter == ARRAY_SIZE(verbs)) return S_FALSE; if(celt) diff --git a/dlls/ieframe/shellbrowser.c b/dlls/ieframe/shellbrowser.c index f75689e..78e0e85 100644 --- a/dlls/ieframe/shellbrowser.c +++ b/dlls/ieframe/shellbrowser.c @@ -658,7 +658,7 @@ static HRESULT WINAPI DocObjectService_FireBeforeNavigate2( VARIANT_BOOL cancel = VARIANT_FALSE; SAFEARRAY *post_data; WCHAR file_path[MAX_PATH]; - DWORD file_path_len = sizeof(file_path) / sizeof(*file_path); + DWORD file_path_len = ARRAY_SIZE(file_path); TRACE("%p %p %s %x %s %p %d %s %d %p\n", This, pDispatch, debugstr_w(lpszUrl), dwFlags, debugstr_w(lpszFrameName), pPostData, cbPostData,
1
0
0
0
Michael Stefaniuc : sane.ds: Use the ARRAY_SIZE() macro.
by Alexandre Julliard
16 Aug '18
16 Aug '18
Module: wine Branch: master Commit: 4e18649c4873f467acca37ff372d83ddd0abfa73 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=4e18649c4873f467acca37ff…
Author: Michael Stefaniuc <mstefani(a)winehq.org> Date: Thu Aug 16 20:19:26 2018 +0200 sane.ds: Use the ARRAY_SIZE() macro. Signed-off-by: Michael Stefaniuc <mstefani(a)winehq.org> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/sane.ds/capability.c | 14 +++++++------- dlls/sane.ds/ui.c | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/dlls/sane.ds/capability.c b/dlls/sane.ds/capability.c index 094bb93..9157cae 100644 --- a/dlls/sane.ds/capability.c +++ b/dlls/sane.ds/capability.c @@ -174,7 +174,7 @@ static TW_UINT16 TWAIN_GetSupportedCaps(pTW_CAPABILITY pCapability) TW_UINT32 i; a = GlobalLock (pCapability->hContainer); a->ItemType = TWTY_UINT16; - a->NumItems = sizeof(supported_caps) / sizeof(supported_caps[0]); + a->NumItems = ARRAY_SIZE(supported_caps); u = (UINT16 *) a->ItemList; for (i = 0; i < a->NumItems; i++) u[i] = supported_caps[i]; @@ -203,7 +203,7 @@ static TW_UINT16 SANE_ICAPXferMech (pTW_CAPABILITY pCapability, TW_UINT16 action break; case MSG_GET: - twCC = msg_get_enum(pCapability, possible_values, sizeof(possible_values) / sizeof(possible_values[0]), + twCC = msg_get_enum(pCapability, possible_values, ARRAY_SIZE(possible_values), TWTY_UINT16, activeDS.capXferMech, TWSX_NATIVE); break; @@ -482,7 +482,7 @@ static TW_UINT16 SANE_ICAPBitDepth(pTW_CAPABILITY pCapability, TW_UINT16 action) break; case MSG_GET: - twCC = msg_get_enum(pCapability, possible_values, sizeof(possible_values) / sizeof(possible_values[0]), + twCC = msg_get_enum(pCapability, possible_values, ARRAY_SIZE(possible_values), TWTY_UINT16, activeDS.sane_param.depth, activeDS.sane_param.depth); break; @@ -536,7 +536,7 @@ static TW_UINT16 SANE_ICAPCompression (pTW_CAPABILITY pCapability, TW_UINT16 act break; case MSG_GET: - twCC = msg_get_enum(pCapability, possible_values, sizeof(possible_values) / sizeof(possible_values[0]), + twCC = msg_get_enum(pCapability, possible_values, ARRAY_SIZE(possible_values), TWTY_UINT16, TWCP_NONE, TWCP_NONE); FIXME("Partial stub: We don't attempt to support compression\n"); break; @@ -731,7 +731,7 @@ static TW_UINT16 SANE_ICAPPixelFlavor (pTW_CAPABILITY pCapability, TW_UINT16 act break; case MSG_GET: - twCC = msg_get_enum(pCapability, possible_values, sizeof(possible_values) / sizeof(possible_values[0]), + twCC = msg_get_enum(pCapability, possible_values, ARRAY_SIZE(possible_values), TWTY_UINT16, flavor, flavor); break; @@ -935,9 +935,9 @@ static TW_UINT16 SANE_ICAPSupportedSizes (pTW_CAPABILITY pCapability, TW_UINT16 break; case MSG_GET: - for (i = 0; i < sizeof(supported_sizes) / sizeof(supported_sizes[0]); i++) + for (i = 0; i < ARRAY_SIZE(supported_sizes); i++) possible_values[i] = supported_sizes[i].size; - twCC = msg_get_enum(pCapability, possible_values, sizeof(possible_values) / sizeof(possible_values[0]), + twCC = msg_get_enum(pCapability, possible_values, ARRAY_SIZE(possible_values), TWTY_UINT16, current_size, default_size); WARN("Partial Stub: our supported size selection is a bit thin.\n"); break; diff --git a/dlls/sane.ds/ui.c b/dlls/sane.ds/ui.c index fe1988a..8a2890c 100644 --- a/dlls/sane.ds/ui.c +++ b/dlls/sane.ds/ui.c @@ -639,7 +639,7 @@ static void UpdateRelevantEdit(HWND hwnd, const SANE_Option_Descriptor *opt, else return; buffer[len++] = ' '; - LoadStringW( SANE_instance, opt->unit, buffer + len, sizeof(buffer)/sizeof(WCHAR) - len ); + LoadStringW( SANE_instance, opt->unit, buffer + len, ARRAY_SIZE( buffer ) - len ); edit_w = GetDlgItem(hwnd,index+ID_BASE+ID_EDIT_BASE); if (edit_w) SetWindowTextW(edit_w,buffer);
1
0
0
0
Michael Stefaniuc : sane.ds: Avoid an ARRAY_SIZE-like macro.
by Alexandre Julliard
16 Aug '18
16 Aug '18
Module: wine Branch: master Commit: 7d550de26391cfe4234568ddffab6a942319dc6b URL:
https://source.winehq.org/git/wine.git/?a=commit;h=7d550de26391cfe4234568dd…
Author: Michael Stefaniuc <mstefani(a)winehq.org> Date: Thu Aug 16 20:19:25 2018 +0200 sane.ds: Avoid an ARRAY_SIZE-like macro. Signed-off-by: Michael Stefaniuc <mstefani(a)winehq.org> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/sane.ds/capability.c | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/dlls/sane.ds/capability.c b/dlls/sane.ds/capability.c index 45c54a1..094bb93 100644 --- a/dlls/sane.ds/capability.c +++ b/dlls/sane.ds/capability.c @@ -844,7 +844,6 @@ static const supported_size_t supported_sizes[] = { TWSS_USEXECUTIVE, 184.15, 266.7 }, { TWSS_A3, 297, 420 }, }; -#define SUPPORTED_SIZE_COUNT (sizeof(supported_sizes) / sizeof(supported_sizes[0])) static TW_UINT16 get_default_paper_size(const supported_size_t *s, int n) { @@ -920,11 +919,11 @@ static TW_UINT16 SANE_ICAPSupportedSizes (pTW_CAPABILITY pCapability, TW_UINT16 TW_UINT16 twCC = TWCC_BADCAP; #ifdef SONAME_LIBSANE - static TW_UINT32 possible_values[SUPPORTED_SIZE_COUNT]; + static TW_UINT32 possible_values[ARRAY_SIZE(supported_sizes)]; unsigned int i; TW_UINT32 val; - TW_UINT16 default_size = get_default_paper_size(supported_sizes, SUPPORTED_SIZE_COUNT); - TW_UINT16 current_size = get_current_paper_size(supported_sizes, SUPPORTED_SIZE_COUNT); + TW_UINT16 default_size = get_default_paper_size(supported_sizes, ARRAY_SIZE(supported_sizes)); + TW_UINT16 current_size = get_current_paper_size(supported_sizes, ARRAY_SIZE(supported_sizes)); TRACE("ICAP_SUPPORTEDSIZES\n"); @@ -946,7 +945,7 @@ static TW_UINT16 SANE_ICAPSupportedSizes (pTW_CAPABILITY pCapability, TW_UINT16 case MSG_SET: twCC = msg_set(pCapability, &val); if (twCC == TWCC_SUCCESS) - for (i = 1; i < SUPPORTED_SIZE_COUNT; i++) + for (i = 1; i < ARRAY_SIZE(supported_sizes); i++) if (supported_sizes[i].size == val) return set_width_height(supported_sizes[i].x, supported_sizes[i].y); @@ -960,7 +959,7 @@ static TW_UINT16 SANE_ICAPSupportedSizes (pTW_CAPABILITY pCapability, TW_UINT16 case MSG_RESET: twCC = TWCC_BADCAP; - for (i = 1; i < SUPPORTED_SIZE_COUNT; i++) + for (i = 1; i < ARRAY_SIZE(supported_sizes); i++) if (supported_sizes[i].size == default_size) { twCC = set_width_height(supported_sizes[i].x, supported_sizes[i].y); @@ -976,7 +975,6 @@ static TW_UINT16 SANE_ICAPSupportedSizes (pTW_CAPABILITY pCapability, TW_UINT16 break; } -#undef SUPPORTED_SIZE_COUNT #endif return twCC; }
1
0
0
0
Nikolay Sivov : gdiplus/tests: Fix region leak (Coverity).
by Alexandre Julliard
16 Aug '18
16 Aug '18
Module: wine Branch: master Commit: a9bc0fec92f0762c1d1178bddc892d2fb43984c5 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=a9bc0fec92f0762c1d1178bd…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Sun Aug 12 22:38:36 2018 +0300 gdiplus/tests: Fix region leak (Coverity). Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Vincent Povirk <vincent(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/gdiplus/tests/graphics.c | 1 + 1 file changed, 1 insertion(+) diff --git a/dlls/gdiplus/tests/graphics.c b/dlls/gdiplus/tests/graphics.c index 5eb0a8a..b0e3d82 100644 --- a/dlls/gdiplus/tests/graphics.c +++ b/dlls/gdiplus/tests/graphics.c @@ -2194,6 +2194,7 @@ static void test_clip_xform(void) expect(0xff, color); GdipDeleteGraphics(graphics); + GdipDeleteRegion(clip); ReleaseDC(hwnd, hdc); }
1
0
0
0
Zebediah Figura : msi/tests: Add a test for asynchronous custom actions.
by Alexandre Julliard
16 Aug '18
16 Aug '18
Module: wine Branch: master Commit: 6387476d99f4f762628cb0d72b2d43c23f76f563 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=6387476d99f4f762628cb0d7…
Author: Zebediah Figura <z.figura12(a)gmail.com> Date: Thu Aug 16 10:34:41 2018 -0500 msi/tests: Add a test for asynchronous custom actions. Signed-off-by: Zebediah Figura <z.figura12(a)gmail.com> Signed-off-by: Hans Leidekker <hans(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/msi/tests/custom.c | 21 +++++++++++++++++++++ dlls/msi/tests/custom.spec | 2 ++ dlls/msi/tests/install.c | 10 +++++++++- 3 files changed, 32 insertions(+), 1 deletion(-) diff --git a/dlls/msi/tests/custom.c b/dlls/msi/tests/custom.c index 3989ca8..6332d68 100644 --- a/dlls/msi/tests/custom.c +++ b/dlls/msi/tests/custom.c @@ -1169,6 +1169,27 @@ UINT WINAPI process2(MSIHANDLE hinst) return ERROR_SUCCESS; } +UINT WINAPI async1(MSIHANDLE hinst) +{ + HANDLE event = CreateEventA(NULL, TRUE, FALSE, "wine_msi_async_test"); + HANDLE event2 = CreateEventA(NULL, TRUE, FALSE, "wine_msi_async_test2"); + DWORD r = WaitForSingleObject(event, 10000); + ok(hinst, !r, "wait timed out\n"); + SetEvent(event2); + return ERROR_SUCCESS; +} + +UINT WINAPI async2(MSIHANDLE hinst) +{ + HANDLE event = CreateEventA(NULL, TRUE, FALSE, "wine_msi_async_test"); + HANDLE event2 = CreateEventA(NULL, TRUE, FALSE, "wine_msi_async_test2"); + DWORD r; + SetEvent(event); + r = WaitForSingleObject(event2, 10000); + ok(hinst, !r, "wait timed out\n"); + return ERROR_SUCCESS; +} + static BOOL pf_exists(const char *file) { char path[MAX_PATH]; diff --git a/dlls/msi/tests/custom.spec b/dlls/msi/tests/custom.spec index b7cbe58..5d78377 100644 --- a/dlls/msi/tests/custom.spec +++ b/dlls/msi/tests/custom.spec @@ -5,6 +5,8 @@ @ stdcall nested(long) @ stdcall process1(long) @ stdcall process2(long) +@ stdcall async1(long) +@ stdcall async2(long) @ stdcall cf_present(long) @ stdcall cf_absent(long) diff --git a/dlls/msi/tests/install.c b/dlls/msi/tests/install.c index e147df6..4fa1862 100644 --- a/dlls/msi/tests/install.c +++ b/dlls/msi/tests/install.c @@ -677,6 +677,8 @@ static const CHAR ca1_install_exec_seq_dat[] = "Action\tCondition\tSequence\n" "process1\tTEST_PROCESS\t720\n" "process2\tTEST_PROCESS\t721\n" "process_deferred\tTEST_PROCESS\t722\n" + "async1\tTEST_ASYNC\t730\n" + "async2\tTEST_ASYNC\t731\n" "InstallFinalize\t\t800\n"; static const CHAR ca1_custom_action_dat[] = "Action\tType\tSource\tTarget\n" @@ -689,6 +691,8 @@ static const CHAR ca1_custom_action_dat[] = "Action\tType\tSource\tTarget\n" "process1\t1\tcustom.dll\tprocess1\n" "process2\t1\tcustom.dll\tprocess2\n" "process_deferred\t1025\tcustom.dll\tprocess2\n" + "async1\t129\tcustom.dll\tasync1\n" + "async2\t1\tcustom.dll\tasync2\n" "testretval\t1\tcustom.dll\ttest_retval\n"; static const CHAR ca1_test_seq_dat[] = "Action\tCondition\tSequence\n" @@ -4129,7 +4133,7 @@ static void test_customaction1(void) r = MsiInstallProductA(msifile, "TEST_RETVAL=0"); ok(r == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %u\n", r); - r = MsiInstallProductA(msifile, "TEST_RETVAL=1626"); /* ERROR_FUNCTION_NOT_CALLED*/ + r = MsiInstallProductA(msifile, "TEST_RETVAL=1626"); /* ERROR_FUNCTION_NOT_CALLED */ ok(r == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %u\n", r); r = MsiInstallProductA(msifile, "TEST_RETVAL=1602"); @@ -4146,6 +4150,10 @@ static void test_customaction1(void) r = MsiInstallProductA(msifile, "TEST_PROCESS=1"); ok(!r, "got %u\n", r); + /* test asynchronous actions (msidbCustomActionTypeAsync) */ + r = MsiInstallProductA(msifile, "TEST_ASYNC=1"); + ok(!r, "got %u\n", r); + delete_test_files(); DeleteFileA(msifile); DeleteFileA("unus");
1
0
0
0
Zebediah Figura : msiexec: Don' t keep the custom action GUID in the main thread's stack.
by Alexandre Julliard
16 Aug '18
16 Aug '18
Module: wine Branch: master Commit: 2592690540a87498db09753a32c416cfe7f26e81 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=2592690540a87498db09753a…
Author: Zebediah Figura <z.figura12(a)gmail.com> Date: Thu Aug 16 10:34:40 2018 -0500 msiexec: Don't keep the custom action GUID in the main thread's stack. Since it could potentially change on us during an asynchronous custom action. Signed-off-by: Zebediah Figura <z.figura12(a)gmail.com> Signed-off-by: Hans Leidekker <hans(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- programs/msiexec/msiexec.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/programs/msiexec/msiexec.c b/programs/msiexec/msiexec.c index ead3bfb..efbcb5c 100644 --- a/programs/msiexec/msiexec.c +++ b/programs/msiexec/msiexec.c @@ -28,6 +28,7 @@ #include <stdio.h> #include "wine/debug.h" +#include "wine/heap.h" #include "wine/unicode.h" #include "initguid.h" @@ -400,20 +401,21 @@ extern UINT CDECL __wine_msi_call_dll_function(GUID *guid); static DWORD CALLBACK custom_action_thread(void *arg) { - GUID *guid = arg; - return __wine_msi_call_dll_function(guid); + GUID guid = *(GUID *)arg; + heap_free(arg); + return __wine_msi_call_dll_function(&guid); } static int custom_action_server(const WCHAR *arg) { static const WCHAR pipe_name[] = {'\\','\\','.','\\','p','i','p','e','\\','m','s','i','c','a','_','%','x','_','%','d',0}; DWORD client_pid = atoiW(arg); + GUID guid, *thread_guid; DWORD64 thread64; WCHAR buffer[24]; HANDLE thread; HANDLE pipe; DWORD size; - GUID guid; TRACE("%s\n", debugstr_w(arg)); @@ -443,7 +445,9 @@ static int custom_action_server(const WCHAR *arg) return 0; } - thread = CreateThread(NULL, 0, custom_action_thread, &guid, 0, NULL); + thread_guid = heap_alloc(sizeof(GUID)); + memcpy(thread_guid, &guid, sizeof(GUID)); + thread = CreateThread(NULL, 0, custom_action_thread, thread_guid, 0, NULL); /* give the thread handle to the client to wait on, since we might have * to run a nested action and can't block during this one */
1
0
0
0
← Newer
1
...
44
45
46
47
48
49
50
...
62
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
Results per page:
10
25
50
100
200