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
May 2006
----- 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
3 participants
863 discussions
Start a n
N
ew thread
Mike McCormack : advapi32: Implement and test SystemFunction002 ( DES decrypt).
by Alexandre Julliard
15 May '06
15 May '06
Module: wine Branch: refs/heads/master Commit: 50ed147db04172f428af8bb123fa9b64d0845934 URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=50ed147db04172f428af8bb…
Author: Mike McCormack <mike(a)codeweavers.com> Date: Fri May 12 00:47:39 2006 +0900 advapi32: Implement and test SystemFunction002 (DES decrypt). --- dlls/advapi32/advapi32.spec | 2 - dlls/advapi32/crypt.h | 2 + dlls/advapi32/crypt_des.c | 77 +++++++++++++++++++++++++++++++++++- dlls/advapi32/crypt_lmhash.c | 23 +++++++++++ dlls/advapi32/tests/crypt_lmhash.c | 23 ++++++++++- 5 files changed, 122 insertions(+), 5 deletions(-) diff --git a/dlls/advapi32/advapi32.spec b/dlls/advapi32/advapi32.spec index c824421..cb747b0 100644 --- a/dlls/advapi32/advapi32.spec +++ b/dlls/advapi32/advapi32.spec @@ -596,7 +596,7 @@ # @ stub StopTraceA # @ stub StopTraceW @ stdcall SynchronizeWindows31FilesAndWindowsNTRegistry(long long long long) @ stdcall SystemFunction001(ptr ptr ptr) -@ stub SystemFunction002 +@ stdcall SystemFunction002(ptr ptr ptr) @ stub SystemFunction003 @ stub SystemFunction004 @ stub SystemFunction005 diff --git a/dlls/advapi32/crypt.h b/dlls/advapi32/crypt.h index f5696e6..207ef5d 100644 --- a/dlls/advapi32/crypt.h +++ b/dlls/advapi32/crypt.h @@ -85,5 +85,7 @@ #define MAXPROVTYPES 999 extern unsigned char *CRYPT_DESkey8to7( unsigned char *dst, const unsigned char *key ); extern unsigned char *CRYPT_DEShash( unsigned char *dst, const unsigned char *key, const unsigned char *src ); +extern unsigned char *CRYPT_DESunhash( unsigned char *dst, const unsigned char *key, + const unsigned char *src ); #endif /* __WINE_CRYPT_H_ */ diff --git a/dlls/advapi32/crypt_des.c b/dlls/advapi32/crypt_des.c index 4b527dd..c2d6e9f 100644 --- a/dlls/advapi32/crypt_des.c +++ b/dlls/advapi32/crypt_des.c @@ -1,5 +1,6 @@ /* * Copyright 2004 Hans Leidekker + * Copyright 2006 Mike McCormack * * Based on DES.c from libcifs * @@ -159,9 +160,9 @@ static void Permute( unsigned char *dst, if (GETBIT( src, map[i] )) SETBIT( dst, i ); } -} +} -static void KeyShift( unsigned char *key, const int numbits ) +static void KeyShiftLeft( unsigned char *key, const int numbits ) { int i; unsigned char keep = key[0]; @@ -190,6 +191,35 @@ static void KeyShift( unsigned char *key } } +static void KeyShiftRight( unsigned char *key, const int numbits ) +{ + int i; + unsigned char keep = key[6]; + + for (i = 0; i < numbits; i++) + { + int j; + + for (j = 7; j >= 0; j--) + { + if (j!=7 && (key[j] & 0x01)) + key[j+1] |= 0x80; + key[j] >>= 1; + } + + if (GETBIT( key, 28 )) + { + CLRBIT( key, 28 ); + SETBIT( key, 0 ); + } + + if (keep & 0x01) + SETBIT( key, 28 ); + + keep >>= 1; + } +} + static void sbox( unsigned char *dst, const unsigned char *src ) { int i; @@ -267,7 +297,7 @@ unsigned char *CRYPT_DEShash( unsigned c unsigned char Rn[4]; unsigned char SubK[6]; - KeyShift( K, KeyRotation[i] ); + KeyShiftLeft( K, KeyRotation[i] ); Permute( SubK, K, KeyCompression, 6 ); Permute( Rexp, R, DataExpansion, 6 ); @@ -288,3 +318,44 @@ unsigned char *CRYPT_DEShash( unsigned c return dst; } + +unsigned char *CRYPT_DESunhash( unsigned char *dst, const unsigned char *key, const unsigned char *src ) +{ + int i; + unsigned char K[7]; + unsigned char D[8]; + + Permute( K, key, KeyPermuteMap, 7 ); + Permute( D, src, InitialPermuteMap, 8 ); + + for (i = 0; i < 16; i++) + { + int j; + unsigned char *L = D; + unsigned char *R = &(D[4]); + unsigned char Rexp[6]; + unsigned char Rn[4]; + unsigned char SubK[6]; + + Permute( SubK, K, KeyCompression, 6 ); + + Permute( Rexp, R, DataExpansion, 6 ); + xor( Rexp, Rexp, SubK, 6 ); + + sbox( Rn, Rexp ); + Permute( Rexp, Rn, PBox, 4 ); + xor( Rn, L, Rexp, 4 ); + + for (j = 0; j < 4; j++) + { + L[j] = R[j]; + R[j] = Rn[j]; + } + + KeyShiftRight( K, KeyRotation[15 - i] ); + } + + Permute( dst, D, FinalPermuteMap, 8 ); + + return dst; +} diff --git a/dlls/advapi32/crypt_lmhash.c b/dlls/advapi32/crypt_lmhash.c index 01f6049..85e29fb 100644 --- a/dlls/advapi32/crypt_lmhash.c +++ b/dlls/advapi32/crypt_lmhash.c @@ -112,3 +112,26 @@ NTSTATUS WINAPI SystemFunction001(const CRYPT_DEShash(output, key, data); return STATUS_SUCCESS; } + +/****************************************************************************** + * SystemFunction002 [ADVAPI32.@] + * + * Decrypts a single block of data using DES + * + * PARAMS + * data [I] data to decrypt (8 bytes) + * key [I] key data (7 bytes) + * output [O] the decrypted data (8 bytes) + * + * RETURNS + * Success: STATUS_SUCCESS + * Failure: STATUS_UNSUCCESSFUL + * + */ +NTSTATUS WINAPI SystemFunction002(const LPBYTE data, const LPBYTE key, LPBYTE output) +{ + if (!data || !output) + return STATUS_UNSUCCESSFUL; + CRYPT_DESunhash(output, key, data); + return STATUS_SUCCESS; +} diff --git a/dlls/advapi32/tests/crypt_lmhash.c b/dlls/advapi32/tests/crypt_lmhash.c index 0e45ddc..c0353d3 100644 --- a/dlls/advapi32/tests/crypt_lmhash.c +++ b/dlls/advapi32/tests/crypt_lmhash.c @@ -37,11 +37,13 @@ struct ustring { typedef VOID (WINAPI *fnSystemFunction006)( PCSTR passwd, PSTR lmhash ); typedef NTSTATUS (WINAPI *fnSystemFunction008)(const LPBYTE, const LPBYTE, LPBYTE); typedef NTSTATUS (WINAPI *fnSystemFunction001)(const LPBYTE, const LPBYTE, LPBYTE); +typedef NTSTATUS (WINAPI *fnSystemFunction002)(const LPBYTE, const LPBYTE, LPBYTE); typedef NTSTATUS (WINAPI *fnSystemFunction032)(struct ustring *, struct ustring *); fnSystemFunction006 pSystemFunction006; fnSystemFunction008 pSystemFunction008; fnSystemFunction001 pSystemFunction001; +fnSystemFunction002 pSystemFunction002; fnSystemFunction032 pSystemFunction032; static void test_SystemFunction006(void) @@ -122,6 +124,21 @@ static void test_SystemFunction001(void) ok(!memcmp(output, expected, sizeof expected), "response wrong\n"); } +static void test_SystemFunction002(void) +{ + /* reverse of SystemFunction001 */ + unsigned char key[8] = { 0xff, 0x37, 0x50, 0xbc, 0xc2, 0xb2, 0x24, 0 }; + unsigned char expected[8] = { 0x01, 0x23, 0x45, 0x67, 0x89, 0xab, 0xcd, 0xef }; + unsigned char data[8] = { 0xc3, 0x37, 0xcd, 0x5c, 0xbd, 0x44, 0xfc, 0x97 }; + unsigned char output[8]; + int r; + + memset(output, 0, sizeof output); + r = pSystemFunction002(data, key, output); + ok(r == STATUS_SUCCESS, "function failed\n"); + ok(!memcmp(output, expected, sizeof expected), "response wrong\n"); +} + static void test_SystemFunction032(void) { struct ustring key, data; @@ -143,7 +160,7 @@ static void test_SystemFunction032(void) r = pSystemFunction032(&data, &key); ok(r == STATUS_SUCCESS, "function failed\n"); - ok( !memcmp(expected, data.Buffer, data.Length), "wrong result\n"); + ok(!memcmp(expected, data.Buffer, data.Length), "wrong result\n"); } START_TEST(crypt_lmhash) @@ -168,5 +185,9 @@ START_TEST(crypt_lmhash) if (pSystemFunction032) test_SystemFunction032(); + pSystemFunction002 = (fnSystemFunction002)GetProcAddress( module, "SystemFunction002" ); + if (pSystemFunction002) + test_SystemFunction002(); + FreeLibrary( module ); }
1
0
0
0
Stefan Dösinger : wined3d: Avoid a NULL dereference in RealizePalette.
by Alexandre Julliard
15 May '06
15 May '06
Module: wine Branch: refs/heads/master Commit: eaec7793d56a31df2cc8270ed0f4e26ae976ef76 URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=eaec7793d56a31df2cc8270…
Author: Stefan Dösinger <stefandoesinger(a)gmx.at> Date: Sun May 14 18:01:31 2006 +0200 wined3d: Avoid a NULL dereference in RealizePalette. --- dlls/wined3d/surface.c | 24 +++++++++++++++++------- 1 files changed, 17 insertions(+), 7 deletions(-) diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c index 22b3f0e..04c3ec3 100644 --- a/dlls/wined3d/surface.c +++ b/dlls/wined3d/surface.c @@ -1773,14 +1773,24 @@ HRESULT WINAPI IWineD3DSurfaceImpl_Reali This->Flags |= SFLAG_DIRTY; } - TRACE("(%p): Updating the palette\n", This); - for (n=0; n<256; n++) { - col[n].rgbRed = pal->palents[n].peRed; - col[n].rgbGreen = pal->palents[n].peGreen; - col[n].rgbBlue = pal->palents[n].peBlue; - col[n].rgbReserved = 0; + if(This->Flags & SFLAG_DIBSECTION) { + TRACE("(%p): Updating the hdc's palette\n", This); + for (n=0; n<256; n++) { + if(pal) { + col[n].rgbRed = pal->palents[n].peRed; + col[n].rgbGreen = pal->palents[n].peGreen; + col[n].rgbBlue = pal->palents[n].peBlue; + } else { + IWineD3DDeviceImpl *device = This->resource.wineD3DDevice; + /* Use the default device palette */ + col[n].rgbRed = device->palettes[device->currentPalette][n].peRed; + col[n].rgbGreen = device->palettes[device->currentPalette][n].peGreen; + col[n].rgbBlue = device->palettes[device->currentPalette][n].peBlue; + } + col[n].rgbReserved = 0; + } + SetDIBColorTable(This->hDC, 0, 256, col); } - SetDIBColorTable(This->hDC, 0, 256, col); return WINED3D_OK; }
1
0
0
0
Stefan Dösinger : wined3d: Render state additions and fixes.
by Alexandre Julliard
15 May '06
15 May '06
Module: wine Branch: refs/heads/master Commit: 34b1482fdccebb6c7708364e04005ac0788ffba6 URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=34b1482fdccebb6c7708364…
Author: Stefan Dösinger <stefan(a)codeweavers.com> Date: Sun May 14 16:47:09 2006 +0200 wined3d: Render state additions and fixes. --- dlls/wined3d/device.c | 46 ++++++++++++++++++++++------------------------ 1 files changed, 22 insertions(+), 24 deletions(-) diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c index a7221ce..ed50b26 100644 --- a/dlls/wined3d/device.c +++ b/dlls/wined3d/device.c @@ -4122,32 +4122,30 @@ #endif } break; } - case WINED3DRS_SEPARATEALPHABLENDENABLE : - case WINED3DRS_SRCBLENDALPHA : - case WINED3DRS_DESTBLENDALPHA : - case WINED3DRS_BLENDOPALPHA : - case WINED3DRS_MULTISAMPLEMASK : - case WINED3DRS_PATCHEDGESTYLE : - case WINED3DRS_PATCHSEGMENTS : - case WINED3DRS_DEBUGMONITORTOKEN : - case WINED3DRS_POSITIONORDER : - case WINED3DRS_NORMALORDER : - case WINED3DRS_MINTESSELLATIONLEVEL : - case WINED3DRS_MAXTESSELLATIONLEVEL : - case WINED3DRS_ADAPTIVETESS_X : - case WINED3DRS_ADAPTIVETESS_Y : - case WINED3DRS_ADAPTIVETESS_Z : - case WINED3DRS_ADAPTIVETESS_W : - case WINED3DRS_ENABLEADAPTIVETESSELLATION : - case WINED3DRS_COLORWRITEENABLE1 : - case WINED3DRS_COLORWRITEENABLE2 : - case WINED3DRS_COLORWRITEENABLE3 : - case WINED3DRS_BLENDFACTOR : - case WINED3DRS_SRGBWRITEENABLE : - FIXME("(%p)->(%s,%ld) not handled yet\n", This, debug_d3drenderstate(State), Value); + + case WINED3DRS_TEXTUREPERSPECTIVE : + { + if (Value) + glHint(GL_PERSPECTIVE_CORRECTION_HINT, GL_NICEST); + else + glHint(GL_PERSPECTIVE_CORRECTION_HINT, GL_FASTEST); + break; + } + + case WINED3DRS_STIPPLEDALPHA : + { + if (Value) + ERR(" Stippled Alpha not supported yet.\n"); + break; + } + case WINED3DRS_ANTIALIAS : + { + if (Value) + ERR(" Antialias not supported yet.\n"); break; + } default: - FIXME("(%p)->(%d,%ld) unrecognized\n", This, State, Value); + FIXME("(%p)->(%s,%ld) not handled yet\n", This, debug_d3drenderstate(State), Value); } LEAVE_GL();
1
0
0
0
Stefan Dösinger : wined3d: Nonpow2 repacking support for GetDC.
by Alexandre Julliard
15 May '06
15 May '06
Module: wine Branch: refs/heads/master Commit: 8af7dd5dea83a129b359d7e9473ec5f9805e24ad URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=8af7dd5dea83a129b359d7e…
Author: Stefan Dösinger <stefan(a)codeweavers.com> Date: Sun May 14 16:28:14 2006 +0200 wined3d: Nonpow2 repacking support for GetDC. --- dlls/wined3d/surface.c | 12 ++++++++++-- 1 files changed, 10 insertions(+), 2 deletions(-) diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c index 48b4e36..22b3f0e 100644 --- a/dlls/wined3d/surface.c +++ b/dlls/wined3d/surface.c @@ -985,8 +985,16 @@ HRESULT WINAPI IWineD3DSurfaceImpl_GetDC } b_info->bmiHeader.biSize = sizeof(BITMAPINFOHEADER); - b_info->bmiHeader.biWidth = This->pow2Width; - b_info->bmiHeader.biHeight = -This->pow2Height; + if( (NP2_REPACK == wined3d_settings.nonpower2_mode || This->resource.usage & WINED3DUSAGE_RENDERTARGET)) { + b_info->bmiHeader.biWidth = This->currentDesc.Width; + b_info->bmiHeader.biHeight = -This->currentDesc.Height; + /* Use the full pow2 image size(assigned below) because LockRect + * will need it for a full glGetTexImage call + */ + } else { + b_info->bmiHeader.biWidth = This->pow2Width; + b_info->bmiHeader.biHeight = -This->pow2Height; + } b_info->bmiHeader.biPlanes = 1; b_info->bmiHeader.biBitCount = This->bytesPerPixel * 8;
1
0
0
0
Stefan Dösinger : wined3d: Support for single buffering.
by Alexandre Julliard
15 May '06
15 May '06
Module: wine Branch: refs/heads/master Commit: daa6a3d714e2c222fdf7c51e410920eebe8ad40c URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=daa6a3d714e2c222fdf7c51…
Author: Stefan Dösinger <stefan(a)codeweavers.com> Date: Sat May 13 23:33:00 2006 +0200 wined3d: Support for single buffering. --- dlls/wined3d/device.c | 41 +++++++++++++++++++++++++++-------------- dlls/wined3d/swapchain.c | 25 +++++++++++++++---------- 2 files changed, 42 insertions(+), 24 deletions(-) diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c index d6c70f8..a7221ce 100644 --- a/dlls/wined3d/device.c +++ b/dlls/wined3d/device.c @@ -1152,9 +1152,6 @@ HRESULT WINAPI IWineD3DDeviceImpl_Create D3DCREATEOBJECTINSTANCE(object, SwapChain) - /* Initialize other useful values */ - object->presentParms.BackBufferCount = 1; /* TODO:? support for gl_aux buffers */ - /********************* * Lookup the window Handle and the relating X window handle ********************/ @@ -1382,18 +1379,34 @@ #endif NULL /* pShared (always null)*/); if (object->frontBuffer != NULL) IWineD3DSurface_SetContainer(object->frontBuffer, (IWineD3DBase *)object); - TRACE("calling rendertarget CB\n"); - hr = D3DCB_CreateRenderTarget((IUnknown *) This->parent, - object->presentParms.BackBufferWidth, - object->presentParms.BackBufferHeight, - object->presentParms.BackBufferFormat, - object->presentParms.MultiSampleType, - object->presentParms.MultiSampleQuality, - TRUE /* Lockable */, - &object->backBuffer, - NULL /* pShared (always null)*/); - if (object->backBuffer != NULL) + if(object->presentParms.BackBufferCount > 0) { + TRACE("calling rendertarget CB\n"); + hr = D3DCB_CreateRenderTarget((IUnknown *) This->parent, + object->presentParms.BackBufferWidth, + object->presentParms.BackBufferHeight, + object->presentParms.BackBufferFormat, + object->presentParms.MultiSampleType, + object->presentParms.MultiSampleQuality, + TRUE /* Lockable */, + &object->backBuffer, + NULL /* pShared (always null)*/); + } else { + object->backBuffer = NULL; + } + + if (object->backBuffer != NULL) { IWineD3DSurface_SetContainer(object->backBuffer, (IWineD3DBase *)object); + ENTER_GL(); + glDrawBuffer(GL_BACK); + checkGLcall("glDrawBuffer(GL_BACK)"); + LEAVE_GL(); + } else { + /* Single buffering - draw to front buffer */ + ENTER_GL(); + glDrawBuffer(GL_FRONT); + checkGLcall("glDrawBuffer(GL_FRONT)"); + LEAVE_GL(); + } /* Under directX swapchains share the depth stencil, so only create one depth-stencil */ if (pPresentationParameters->EnableAutoDepthStencil) { diff --git a/dlls/wined3d/swapchain.c b/dlls/wined3d/swapchain.c index 05e31e4..29c3f1c 100644 --- a/dlls/wined3d/swapchain.c +++ b/dlls/wined3d/swapchain.c @@ -94,19 +94,24 @@ ULONG WINAPI IWineD3DSwapChainImpl_Relea IWineD3DDevice_SwapChainReleased((IWineD3DDevice *)This->wineD3DDevice, iface); /* release the ref to the front and back buffer parents */ - IWineD3DSurface_SetContainer(This->frontBuffer, 0); - IWineD3DSurface_GetParent(This->frontBuffer, &bufferParent); - IUnknown_Release(bufferParent); /* once for the get parent */ - if(IUnknown_Release(bufferParent) > 0){ - FIXME("(%p) Something's still holding the front buffer\n",This); + if(This->frontBuffer) { + IWineD3DSurface_SetContainer(This->frontBuffer, 0); + IWineD3DSurface_GetParent(This->frontBuffer, &bufferParent); + IUnknown_Release(bufferParent); /* once for the get parent */ + if(IUnknown_Release(bufferParent) > 0){ + FIXME("(%p) Something's still holding the front buffer\n",This); + } } - IWineD3DSurface_SetContainer(This->backBuffer, 0); - IWineD3DSurface_GetParent(This->backBuffer, &bufferParent); - IUnknown_Release(bufferParent); /* once for the get parent */ - if(IUnknown_Release(bufferParent) > 0){ - FIXME("(%p) Something's still holding the back buffer\n",This); + if(This->backBuffer) { + IWineD3DSurface_SetContainer(This->backBuffer, 0); + IWineD3DSurface_GetParent(This->backBuffer, &bufferParent); + IUnknown_Release(bufferParent); /* once for the get parent */ + if(IUnknown_Release(bufferParent) > 0){ + FIXME("(%p) Something's still holding the back buffer\n",This); + } } + /* Clean up the context */ /* check that we are the current context first */ if(glXGetCurrentContext() == This->glCtx){
1
0
0
0
Stefan Dösinger : wined3d: Implement IWineGDISurface.
by Alexandre Julliard
15 May '06
15 May '06
Module: wine Branch: refs/heads/master Commit: 2f724834f8b99d11287d4f49a4a7e4c52546abf9 URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=2f724834f8b99d11287d4f4…
Author: Stefan Dösinger <stefandoesinger(a)gmx.at> Date: Sat May 13 22:22:16 2006 +0200 wined3d: Implement IWineGDISurface. --- dlls/wined3d/Makefile.in | 1 dlls/wined3d/device.c | 25 + dlls/wined3d/surface_gdi.c | 1502 ++++++++++++++++++++++++++++++++++++++++ dlls/wined3d/utils.c | 13 dlls/wined3d/wined3d_private.h | 47 + 5 files changed, 1587 insertions(+), 1 deletions(-) create mode 100644 dlls/wined3d/surface_gdi.c Diff:
http://source.winehq.org/git/?p=wine.git;a=commitdiff;h=2f724834f8b99d11287…
1
0
0
0
Stefan Dösinger : wined3d: Implement IWineD3DDevice:: ProcessVertices.
by Alexandre Julliard
15 May '06
15 May '06
Module: wine Branch: refs/heads/master Commit: 9abdac6aaa593bfd704a8222c2c15caf9ce84159 URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=9abdac6aaa593bfd704a822…
Author: Stefan Dösinger <stefandoesinger(a)gmx.at> Date: Fri May 12 22:21:31 2006 +0200 wined3d: Implement IWineD3DDevice::ProcessVertices. --- dlls/wined3d/device.c | 307 +++++++++++++++++++++++++++++++++++----- dlls/wined3d/drawprim.c | 2 dlls/wined3d/utils.c | 50 +++++++ dlls/wined3d/wined3d_private.h | 11 + 4 files changed, 331 insertions(+), 39 deletions(-) Diff:
http://source.winehq.org/git/?p=wine.git;a=commitdiff;h=9abdac6aaa593bfd704…
1
0
0
0
Mike McCormack : rpcrt4: Add missing PKT_AUTH3 packet type.
by Alexandre Julliard
15 May '06
15 May '06
Module: wine Branch: refs/heads/master Commit: a9886585de407db73e118be903df9d96614b2fb9 URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=a9886585de407db73e118be…
Author: Mike McCormack <mike(a)codeweavers.com> Date: Fri May 12 19:47:22 2006 +0900 rpcrt4: Add missing PKT_AUTH3 packet type. --- dlls/rpcrt4/rpc_defs.h | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/dlls/rpcrt4/rpc_defs.h b/dlls/rpcrt4/rpc_defs.h index 9e9a735..5d23600 100644 --- a/dlls/rpcrt4/rpc_defs.h +++ b/dlls/rpcrt4/rpc_defs.h @@ -160,6 +160,7 @@ #define PKT_BIND_ACK 12 #define PKT_BIND_NACK 13 #define PKT_ALTER_CONTEXT 14 #define PKT_ALTER_CONTEXT_RESP 15 +#define PKT_AUTH3 16 #define PKT_SHUTDOWN 17 #define PKT_CO_CANCEL 18 #define PKT_ORPHANED 19
1
0
0
0
Mike McCormack : rpcrt4: Add infrastructure for send authentication data.
by Alexandre Julliard
15 May '06
15 May '06
Module: wine Branch: refs/heads/master Commit: 7b5e5b65b0ebfc413d741fb165b1f3d1af2cb2f9 URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=7b5e5b65b0ebfc413d741fb…
Author: Mike McCormack <mike(a)codeweavers.com> Date: Fri May 12 19:20:26 2006 +0900 rpcrt4: Add infrastructure for send authentication data. --- dlls/rpcrt4/rpc_message.c | 69 ++++++++++++++++++++++++++++++++------------- 1 files changed, 49 insertions(+), 20 deletions(-) diff --git a/dlls/rpcrt4/rpc_message.c b/dlls/rpcrt4/rpc_message.c index 7646f98..014d60a 100644 --- a/dlls/rpcrt4/rpc_message.c +++ b/dlls/rpcrt4/rpc_message.c @@ -239,53 +239,71 @@ VOID RPCRT4_FreeHeader(RpcPktHdr *Header } /*********************************************************************** - * RPCRT4_Send (internal) + * RPCRT4_SendAuth (internal) * - * Transmit a packet over connection in acceptable fragments. + * Transmit a packet with authorization data over connection in acceptable fragments. */ -RPC_STATUS RPCRT4_Send(RpcConnection *Connection, RpcPktHdr *Header, - void *Buffer, unsigned int BufferLength) +static RPC_STATUS RPCRT4_SendAuth(RpcConnection *Connection, RpcPktHdr *Header, + void *Buffer, unsigned int BufferLength, + void *Auth, unsigned int AuthLength) { PUCHAR buffer_pos; DWORD hdr_size; LONG count; + unsigned char *pkt, *auth_hdr; + LONG alen = AuthLength ? (AuthLength + 8) : 0; buffer_pos = Buffer; /* The packet building functions save the packet header size, so we can use it. */ hdr_size = Header->common.frag_len; + Header->common.auth_len = AuthLength; Header->common.flags |= RPC_FLG_FIRST; Header->common.flags &= ~RPC_FLG_LAST; while (!(Header->common.flags & RPC_FLG_LAST)) { /* decide if we need to split the packet into fragments */ - if ((BufferLength + hdr_size) <= Connection->MaxTransmissionSize) { + if ((BufferLength + hdr_size + alen) <= Connection->MaxTransmissionSize) { Header->common.flags |= RPC_FLG_LAST; - Header->common.frag_len = BufferLength + hdr_size; + Header->common.frag_len = BufferLength + hdr_size + alen; } else { Header->common.frag_len = Connection->MaxTransmissionSize; } - /* transmit packet header */ - count = rpcrt4_conn_write(Connection, Header, hdr_size); - if (count<0) { - WARN("rpcrt4_conn_write failed\n"); - return RPC_S_PROTOCOL_ERROR; - } + pkt = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, Header->common.frag_len); + + memcpy(pkt, Header, hdr_size); /* fragment consisted of header only and is the last one */ - if (hdr_size == Header->common.frag_len && - Header->common.flags & RPC_FLG_LAST) { - return RPC_S_OK; + if (hdr_size == Header->common.frag_len) + goto write; + + memcpy(pkt + hdr_size, buffer_pos, Header->common.frag_len - hdr_size - alen); + + /* add the authorization info */ + if (AuthLength) + { + auth_hdr = &pkt[Header->common.frag_len - alen]; + + /* FIXME: is this per fragment or per message? */ + auth_hdr[0] = RPC_C_AUTHN_WINNT; + auth_hdr[1] = RPC_C_AUTHN_LEVEL_CONNECT; + auth_hdr[2] = 0x00; /* FIXME: add padding */ + auth_hdr[3] = 0x00; + + /* a unique number... */ + memcpy(&auth_hdr[4], &Connection, 4); + memcpy(&auth_hdr[8], Auth, AuthLength); } - /* send the fragment data */ - count = rpcrt4_conn_write(Connection, buffer_pos, Header->common.frag_len - hdr_size); +write: + count = rpcrt4_conn_write(Connection, pkt, Header->common.frag_len); + HeapFree(GetProcessHeap(), 0, pkt); if (count<0) { - WARN("rpcrt4_conn_write failed\n"); + WARN("rpcrt4_conn_write failed (auth)\n"); return RPC_S_PROTOCOL_ERROR; } - buffer_pos += Header->common.frag_len - hdr_size; - BufferLength -= Header->common.frag_len - hdr_size; + buffer_pos += Header->common.frag_len - hdr_size - alen; + BufferLength -= Header->common.frag_len - hdr_size - alen; Header->common.flags &= ~RPC_FLG_FIRST; } @@ -293,6 +311,17 @@ RPC_STATUS RPCRT4_Send(RpcConnection *Co } /*********************************************************************** + * RPCRT4_Send (internal) + * + * Transmit a packet over connection in acceptable fragments. + */ +RPC_STATUS RPCRT4_Send(RpcConnection *Connection, RpcPktHdr *Header, + void *Buffer, unsigned int BufferLength) +{ + return RPCRT4_SendAuth(Connection, Header, Buffer, BufferLength, NULL, 0); +} + +/*********************************************************************** * RPCRT4_Receive (internal) * * Receive a packet from connection and merge the fragments.
1
0
0
0
Mike McCormack : rpcrt4: Forward RpcBindingSetAuthInfo to RpcBindingSetAuthInfoEx.
by Alexandre Julliard
15 May '06
15 May '06
Module: wine Branch: refs/heads/master Commit: 1912fceab6b89774cbe0a25db3fb38260a0ee2dc URL:
http://source.winehq.org/git/?p=wine.git;a=commit;h=1912fceab6b89774cbe0a25…
Author: Mike McCormack <mike(a)codeweavers.com> Date: Fri May 12 19:19:48 2006 +0900 rpcrt4: Forward RpcBindingSetAuthInfo to RpcBindingSetAuthInfoEx. --- dlls/rpcrt4/rpc_binding.c | 10 +++++----- 1 files changed, 5 insertions(+), 5 deletions(-) diff --git a/dlls/rpcrt4/rpc_binding.c b/dlls/rpcrt4/rpc_binding.c index 5991eee..219b2ee 100644 --- a/dlls/rpcrt4/rpc_binding.c +++ b/dlls/rpcrt4/rpc_binding.c @@ -1023,11 +1023,11 @@ RpcBindingSetAuthInfoExW( RPC_BINDING_HA */ RPCRTAPI RPC_STATUS RPC_ENTRY RpcBindingSetAuthInfoA( RPC_BINDING_HANDLE Binding, unsigned char *ServerPrincName, unsigned long AuthnLevel, - unsigned long AuthnSvc, RPC_AUTH_IDENTITY_HANDLE AuthIdentity, unsigned long AuthzSvr ) + unsigned long AuthnSvc, RPC_AUTH_IDENTITY_HANDLE AuthIdentity, unsigned long AuthzSvr ) { - FIXME("%p %s %lu %lu %p %lu\n", Binding, debugstr_a((const char*)ServerPrincName), + TRACE("%p %s %lu %lu %p %lu\n", Binding, debugstr_a((const char*)ServerPrincName), AuthnLevel, AuthnSvc, AuthIdentity, AuthzSvr); - return RPC_S_OK; + return RpcBindingSetAuthInfoExA(Binding, ServerPrincName, AuthnLevel, AuthnSvc, AuthIdentity, AuthzSvr, NULL); } /*********************************************************************** @@ -1037,9 +1037,9 @@ RPCRTAPI RPC_STATUS RPC_ENTRY RpcBindingSetAuthInfoW( RPC_BINDING_HANDLE Binding, unsigned short *ServerPrincName, unsigned long AuthnLevel, unsigned long AuthnSvc, RPC_AUTH_IDENTITY_HANDLE AuthIdentity, unsigned long AuthzSvr ) { - FIXME("%p %s %lu %lu %p %lu\n", Binding, debugstr_w((const WCHAR*)ServerPrincName), + TRACE("%p %s %lu %lu %p %lu\n", Binding, debugstr_w((const WCHAR*)ServerPrincName), AuthnLevel, AuthnSvc, AuthIdentity, AuthzSvr); - return RPC_S_OK; + return RpcBindingSetAuthInfoExW(Binding, ServerPrincName, AuthnLevel, AuthnSvc, AuthIdentity, AuthzSvr, NULL); } /***********************************************************************
1
0
0
0
← Newer
1
...
48
49
50
51
52
53
54
...
87
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
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
Results per page:
10
25
50
100
200