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
June
May
April
March
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
October 2007
----- 2025 -----
June 2025
May 2025
April 2025
March 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
4 participants
996 discussions
Start a n
N
ew thread
Michael Stefaniuc : winealsa.drv: Leave the CriticalSection before destroying it. Found by Smatch.
by Alexandre Julliard
23 Oct '07
23 Oct '07
Module: wine Branch: master Commit: ca71287572bb358250186d6c5b3fd6a9cfd8c6a0 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=ca71287572bb358250186d6c5…
Author: Michael Stefaniuc <mstefani(a)redhat.de> Date: Mon Oct 22 22:46:05 2007 +0200 winealsa.drv: Leave the CriticalSection before destroying it. Found by Smatch. --- dlls/winealsa.drv/mixer.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/dlls/winealsa.drv/mixer.c b/dlls/winealsa.drv/mixer.c index f1b2e12..daa45a1 100644 --- a/dlls/winealsa.drv/mixer.c +++ b/dlls/winealsa.drv/mixer.c @@ -573,6 +573,7 @@ static void ALSA_MixerExit(void) EnterCriticalSection(&elem_crst); TerminateThread(thread, 1); refcnt = 0; + LeaveCriticalSection(&elem_crst); } TRACE("Cleaning up\n");
1
0
0
0
Michael Stefaniuc : winealsa.drv: Leave the CriticalSection before destroying it. Found by Smatch.
by Alexandre Julliard
23 Oct '07
23 Oct '07
Module: wine Branch: master Commit: ad99cb46c676c517b957e18a78e51bb5fe95883d URL:
http://source.winehq.org/git/wine.git/?a=commit;h=ad99cb46c676c517b957e18a7…
Author: Michael Stefaniuc <mstefani(a)redhat.de> Date: Mon Oct 22 22:45:54 2007 +0200 winealsa.drv: Leave the CriticalSection before destroying it. Found by Smatch. --- dlls/winealsa.drv/dscapture.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/dlls/winealsa.drv/dscapture.c b/dlls/winealsa.drv/dscapture.c index 3e6984a..168fc91 100644 --- a/dlls/winealsa.drv/dscapture.c +++ b/dlls/winealsa.drv/dscapture.c @@ -534,6 +534,7 @@ static ULONG WINAPI IDsCaptureDriverBufferImpl_Release(PIDSCDRIVERBUFFER iface) TRACE("mmap buffer %p destroyed\n", This->mmap_buffer); This->drv->capture_buffer = NULL; + LeaveCriticalSection(&This->pcm_crst); This->pcm_crst.DebugInfo->Spare[0] = 0; DeleteCriticalSection(&This->pcm_crst);
1
0
0
0
Detlef Riekenberg : comdlg32: Do not crash with PageSetupDlg(NULL).
by Alexandre Julliard
23 Oct '07
23 Oct '07
Module: wine Branch: master Commit: 55fe39e07b6070df17311c65a192ad0fe321c907 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=55fe39e07b6070df17311c65a…
Author: Detlef Riekenberg <wine.dev(a)web.de> Date: Mon Oct 22 18:18:41 2007 +0200 comdlg32: Do not crash with PageSetupDlg(NULL). --- dlls/comdlg32/printdlg.c | 16 ++++++++++++---- 1 files changed, 12 insertions(+), 4 deletions(-) diff --git a/dlls/comdlg32/printdlg.c b/dlls/comdlg32/printdlg.c index 490a794..b995624 100644 --- a/dlls/comdlg32/printdlg.c +++ b/dlls/comdlg32/printdlg.c @@ -3383,6 +3383,11 @@ BOOL WINAPI PageSetupDlgA(LPPAGESETUPDLGA setupdlg) { PageSetupDataA *pda; PRINTDLGA pdlg; + if (setupdlg == NULL) { + COMDLG32_SetCommDlgExtendedError(CDERR_INITIALIZATION); + return FALSE; + } + /* TRACE */ if(TRACE_ON(commdlg)) { char flagstr[1000] = ""; @@ -3399,11 +3404,8 @@ BOOL WINAPI PageSetupDlgA(LPPAGESETUPDLGA setupdlg) { setupdlg->hDevNames, setupdlg->hInstance, setupdlg->Flags, flagstr); } + /* Checking setupdlg structure */ - if (setupdlg == NULL) { - COMDLG32_SetCommDlgExtendedError(CDERR_INITIALIZATION); - return FALSE; - } if(setupdlg->lStructSize != sizeof(PAGESETUPDLGA)) { COMDLG32_SetCommDlgExtendedError(CDERR_STRUCTSIZE); return FALSE; @@ -3488,6 +3490,12 @@ BOOL WINAPI PageSetupDlgW(LPPAGESETUPDLGW setupdlg) { PRINTDLGW pdlg; FIXME("Unicode implementation is not done yet\n"); + + if (setupdlg == NULL) { + COMDLG32_SetCommDlgExtendedError(CDERR_INITIALIZATION); + return FALSE; + } + if(TRACE_ON(commdlg)) { char flagstr[1000] = ""; const struct pd_flags *pflag = psd_flags;
1
0
0
0
Juan Lang : cryptnet: Implement CryptRetrieveObjectByUrlW for the http protocol.
by Alexandre Julliard
23 Oct '07
23 Oct '07
Module: wine Branch: master Commit: d1d0c97c84f579ba293de9d62d0a1cafd4f9267e URL:
http://source.winehq.org/git/wine.git/?a=commit;h=d1d0c97c84f579ba293de9d62…
Author: Juan Lang <juan.lang(a)gmail.com> Date: Mon Oct 22 10:25:08 2007 -0700 cryptnet: Implement CryptRetrieveObjectByUrlW for the http protocol. --- dlls/cryptnet/cryptnet_main.c | 520 ++++++++++++++++++++++++++++++++++++----- 1 files changed, 465 insertions(+), 55 deletions(-) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=d1d0c97c84f579ba293de…
1
0
0
0
Juan Lang : cryptnet: Return FALSE if the requested URL exists and the url array size is NULL.
by Alexandre Julliard
23 Oct '07
23 Oct '07
Module: wine Branch: master Commit: dcb8c874e875695208dd230e64f39120582921f9 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=dcb8c874e875695208dd230e6…
Author: Juan Lang <juan.lang(a)gmail.com> Date: Mon Oct 22 10:22:50 2007 -0700 cryptnet: Return FALSE if the requested URL exists and the url array size is NULL. --- dlls/cryptnet/cryptnet_main.c | 3 +++ dlls/cryptnet/tests/cryptnet.c | 2 -- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/dlls/cryptnet/cryptnet_main.c b/dlls/cryptnet/cryptnet_main.c index 049e52d..3a25fb5 100644 --- a/dlls/cryptnet/cryptnet_main.c +++ b/dlls/cryptnet/cryptnet_main.c @@ -174,7 +174,10 @@ static BOOL WINAPI CRYPT_GetUrlFromCertificateCRLDistPoint(LPCSTR pszUrlOid, } } if (!pcbUrlArray) + { SetLastError(E_INVALIDARG); + ret = FALSE; + } else if (!pUrlArray) *pcbUrlArray = bytesNeeded; else if (*pcbUrlArray < bytesNeeded) diff --git a/dlls/cryptnet/tests/cryptnet.c b/dlls/cryptnet/tests/cryptnet.c index 221a29d..25edaa6 100644 --- a/dlls/cryptnet/tests/cryptnet.c +++ b/dlls/cryptnet/tests/cryptnet.c @@ -175,13 +175,11 @@ static void test_getObjectUrl(void) SetLastError(0xdeadbeef); ret = CryptGetObjectUrl(URL_OID_CERTIFICATE_CRL_DIST_POINT, (void *)cert, 0, NULL, NULL, NULL, NULL, NULL); - todo_wine ok(!ret && GetLastError() == E_INVALIDARG, "Expected E_INVALIDARG, got %08x\n", GetLastError()); SetLastError(0xdeadbeef); ret = CryptGetObjectUrl(URL_OID_CERTIFICATE_CRL_DIST_POINT, (void *)cert, 0, NULL, NULL, NULL, &infoSize, NULL); - todo_wine ok(!ret && GetLastError() == E_INVALIDARG, "Expected E_INVALIDARG, got %08x\n", GetLastError()); /* Can get it without specifying the location: */
1
0
0
0
Juan Lang : cryptnet: Implement CryptRetrieveObjectByUrlW for the file: protocol.
by Alexandre Julliard
23 Oct '07
23 Oct '07
Module: wine Branch: master Commit: 681a408aa641f71e70c6d498c4ca946709e21b16 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=681a408aa641f71e70c6d498c…
Author: Juan Lang <juan.lang(a)gmail.com> Date: Mon Oct 22 10:22:16 2007 -0700 cryptnet: Implement CryptRetrieveObjectByUrlW for the file: protocol. --- dlls/cryptnet/Makefile.in | 1 + dlls/cryptnet/cryptnet_main.c | 548 +++++++++++++++++++++++++++++++++++++++- dlls/cryptnet/tests/cryptnet.c | 17 +- 3 files changed, 551 insertions(+), 15 deletions(-) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=681a408aa641f71e70c6d…
1
0
0
0
Juan Lang : cryptnet: Implement CryptRetrieveObjectByUrlA on top of CryptRetrieveObjectByUrlW.
by Alexandre Julliard
23 Oct '07
23 Oct '07
Module: wine Branch: master Commit: 1fbb0f6a5ae82f74dc91d2fbb4c195bef2bcbec9 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=1fbb0f6a5ae82f74dc91d2fbb…
Author: Juan Lang <juan.lang(a)gmail.com> Date: Mon Oct 22 10:20:11 2007 -0700 cryptnet: Implement CryptRetrieveObjectByUrlA on top of CryptRetrieveObjectByUrlW. --- dlls/cryptnet/cryptnet_main.c | 30 ++++++++++++++++++++++++++++-- dlls/cryptnet/tests/cryptnet.c | 1 - 2 files changed, 28 insertions(+), 3 deletions(-) diff --git a/dlls/cryptnet/cryptnet_main.c b/dlls/cryptnet/cryptnet_main.c index 0c5843b..669b12e 100644 --- a/dlls/cryptnet/cryptnet_main.c +++ b/dlls/cryptnet/cryptnet_main.c @@ -24,6 +24,7 @@ #include "wine/debug.h" #include "winbase.h" #include "winnt.h" +#include "winnls.h" #define NONAMELESSUNION #include "wincrypt.h" @@ -298,10 +299,35 @@ BOOL WINAPI CryptRetrieveObjectByUrlA(LPCSTR pszURL, LPCSTR pszObjectOid, HCRYPTASYNC hAsyncRetrieve, PCRYPT_CREDENTIALS pCredentials, LPVOID pvVerify, PCRYPT_RETRIEVE_AUX_INFO pAuxInfo) { - FIXME("(%s, %s, %08x, %d, %p, %p, %p, %p, %p)\n", debugstr_a(pszURL), + BOOL ret = FALSE; + int len; + + TRACE("(%s, %s, %08x, %d, %p, %p, %p, %p, %p)\n", debugstr_a(pszURL), debugstr_a(pszObjectOid), dwRetrievalFlags, dwTimeout, ppvObject, hAsyncRetrieve, pCredentials, pvVerify, pAuxInfo); - return FALSE; + + if (!pszURL) + { + SetLastError(ERROR_INVALID_PARAMETER); + return FALSE; + } + len = MultiByteToWideChar(CP_ACP, 0, pszURL, -1, NULL, 0); + if (len) + { + LPWSTR url = CryptMemAlloc(len * sizeof(WCHAR)); + + if (url) + { + MultiByteToWideChar(CP_ACP, 0, pszURL, -1, url, len); + ret = CryptRetrieveObjectByUrlW(url, pszObjectOid, + dwRetrievalFlags, dwTimeout, ppvObject, hAsyncRetrieve, + pCredentials, pvVerify, pAuxInfo); + CryptMemFree(url); + } + else + SetLastError(ERROR_OUTOFMEMORY); + } + return ret; } /*********************************************************************** diff --git a/dlls/cryptnet/tests/cryptnet.c b/dlls/cryptnet/tests/cryptnet.c index a8f1db0..d1c4787 100644 --- a/dlls/cryptnet/tests/cryptnet.c +++ b/dlls/cryptnet/tests/cryptnet.c @@ -267,7 +267,6 @@ static void test_retrieveObjectByUrl(void) SetLastError(0xdeadbeef); ret = CryptRetrieveObjectByUrlA(NULL, NULL, 0, 0, NULL, NULL, NULL, NULL, NULL); - todo_wine ok(!ret && GetLastError() == ERROR_INVALID_PARAMETER, "Expected ERROR_INVALID_PARAMETER, got %08x\n", GetLastError());
1
0
0
0
Juan Lang : cryptnet: Add tests for CryptRetrieveObjectByUrl.
by Alexandre Julliard
23 Oct '07
23 Oct '07
Module: wine Branch: master Commit: a7cfe075c864966025deb39ca289ed39c3c444cf URL:
http://source.winehq.org/git/wine.git/?a=commit;h=a7cfe075c864966025deb39ca…
Author: Juan Lang <juan.lang(a)gmail.com> Date: Mon Oct 22 10:19:36 2007 -0700 cryptnet: Add tests for CryptRetrieveObjectByUrl. --- dlls/cryptnet/tests/cryptnet.c | 137 ++++++++++++++++++++++++++++++++++++++++ 1 files changed, 137 insertions(+), 0 deletions(-) diff --git a/dlls/cryptnet/tests/cryptnet.c b/dlls/cryptnet/tests/cryptnet.c index 8862d16..a8f1db0 100644 --- a/dlls/cryptnet/tests/cryptnet.c +++ b/dlls/cryptnet/tests/cryptnet.c @@ -18,6 +18,7 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ #include <stdarg.h> +#include <stdio.h> #define NONAMELESSUNION #include <windef.h> #include <winbase.h> @@ -234,7 +235,143 @@ static void test_getObjectUrl(void) } } +static void make_tmp_file(LPSTR path) +{ + static char curr[MAX_PATH] = { 0 }; + char temp[MAX_PATH]; + DWORD dwNumberOfBytesWritten; + HANDLE hf; + + if (!*curr) + GetCurrentDirectoryA(MAX_PATH, curr); + GetTempFileNameA(curr, "net", 0, temp); + lstrcpyA(path, temp); + hf = CreateFileA(path, GENERIC_WRITE, 0, NULL, CREATE_ALWAYS, + FILE_ATTRIBUTE_NORMAL, NULL); + WriteFile(hf, certWithCRLDistPoint, sizeof(certWithCRLDistPoint), + &dwNumberOfBytesWritten, NULL); + CloseHandle(hf); +} + +static void test_retrieveObjectByUrl(void) +{ + BOOL ret; + char tmpfile[MAX_PATH * 2], *ptr, url[MAX_PATH + 8]; + CRYPT_BLOB_ARRAY *pBlobArray; + PCCERT_CONTEXT cert; + PCCRL_CONTEXT crl; + HCERTSTORE store; + CRYPT_RETRIEVE_AUX_INFO aux = { 0 }; + FILETIME ft = { 0 }; + + SetLastError(0xdeadbeef); + ret = CryptRetrieveObjectByUrlA(NULL, NULL, 0, 0, NULL, NULL, NULL, NULL, + NULL); + todo_wine + ok(!ret && GetLastError() == ERROR_INVALID_PARAMETER, + "Expected ERROR_INVALID_PARAMETER, got %08x\n", GetLastError()); + + make_tmp_file(tmpfile); + ptr = strchr(tmpfile, ':'); + if (ptr) + ptr += 2; /* skip colon and first slash */ + else + ptr = tmpfile; + snprintf(url, sizeof(url), "file:///%s", ptr); + do { + ptr = strchr(url, '\\'); + if (ptr) + *ptr = '/'; + } while (ptr); + + pBlobArray = (CRYPT_BLOB_ARRAY *)0xdeadbeef; + ret = CryptRetrieveObjectByUrlA(url, NULL, 0, 0, (void **)&pBlobArray, + NULL, NULL, NULL, NULL); + todo_wine + ok(ret, "CryptRetrieveObjectByUrlA failed: %d\n", GetLastError()); + todo_wine + ok(pBlobArray && pBlobArray != (CRYPT_BLOB_ARRAY *)0xdeadbeef, + "Expected a valid pointer\n"); + if (pBlobArray && pBlobArray != (CRYPT_BLOB_ARRAY *)0xdeadbeef) + { + ok(pBlobArray->cBlob == 1, "Expected 1 blob, got %d\n", + pBlobArray->cBlob); + ok(pBlobArray->rgBlob[0].cbData == sizeof(certWithCRLDistPoint), + "Unexpected size %d\n", pBlobArray->rgBlob[0].cbData); + CryptMemFree(pBlobArray); + } + cert = (PCCERT_CONTEXT)0xdeadbeef; + ret = CryptRetrieveObjectByUrlA(url, CONTEXT_OID_CERTIFICATE, 0, 0, + (void **)&cert, NULL, NULL, NULL, NULL); + todo_wine + ok(cert && cert != (PCCERT_CONTEXT)0xdeadbeef, "Expected a cert\n"); + if (cert && cert != (PCCERT_CONTEXT)0xdeadbeef) + CertFreeCertificateContext(cert); + crl = (PCCRL_CONTEXT)0xdeadbeef; + SetLastError(0xdeadbeef); + ret = CryptRetrieveObjectByUrlA(url, CONTEXT_OID_CRL, 0, 0, (void **)&crl, + NULL, NULL, NULL, NULL); + todo_wine + ok(!ret && GetLastError() == CRYPT_E_NO_MATCH, + "Expected CRYPT_E_NO_MATCH, got %08x\n", GetLastError()); + todo_wine + ok(crl == NULL, "Expected CRL to be NULL\n"); + if (crl && crl != (PCCRL_CONTEXT)0xdeadbeef) + CertFreeCRLContext(crl); + store = (HCERTSTORE)0xdeadbeef; + ret = CryptRetrieveObjectByUrlA(url, CONTEXT_OID_CAPI2_ANY, 0, 0, + (void **)&store, NULL, NULL, NULL, NULL); + todo_wine + ok(ret, "CryptRetrieveObjectByUrlA failed: %d\n", GetLastError()); + if (store && store != (HCERTSTORE)0xdeadbeef) + { + DWORD certs = 0; + + cert = NULL; + do { + cert = CertEnumCertificatesInStore(store, cert); + if (cert) + certs++; + } while (cert); + ok(certs == 1, "Expected 1 cert, got %d\n", certs); + CertCloseStore(store, 0); + } + /* Are file URLs cached? */ + ret = CryptRetrieveObjectByUrlA(url, CONTEXT_OID_CERTIFICATE, + CRYPT_CACHE_ONLY_RETRIEVAL, 0, (void **)&cert, NULL, NULL, NULL, NULL); + todo_wine + ok(ret, "CryptRetrieveObjectByUrlA failed: %08x\n", GetLastError()); + if (cert && cert != (PCCERT_CONTEXT)0xdeadbeef) + CertFreeCertificateContext(cert); + ret = CryptRetrieveObjectByUrlA(url, CONTEXT_OID_CERTIFICATE, 0, 0, + (void **)&cert, NULL, NULL, NULL, &aux); + todo_wine + ok(ret, "CryptRetrieveObjectByUrlA failed: %08x\n", GetLastError()); + if (cert && cert != (PCCERT_CONTEXT)0xdeadbeef) + CertFreeCertificateContext(cert); + aux.cbSize = sizeof(aux); + ret = CryptRetrieveObjectByUrlA(url, CONTEXT_OID_CERTIFICATE, 0, 0, + (void **)&cert, NULL, NULL, NULL, &aux); + todo_wine + ok(ret, "CryptRetrieveObjectByUrlA failed: %08x\n", GetLastError()); + aux.pLastSyncTime = &ft; + ret = CryptRetrieveObjectByUrlA(url, CONTEXT_OID_CERTIFICATE, 0, 0, + (void **)&cert, NULL, NULL, NULL, &aux); + todo_wine + ok(ft.dwLowDateTime || ft.dwHighDateTime, + "Expected last sync time to be set\n"); + DeleteFileA(tmpfile); + /* Okay, after being deleted, are file URLs still cached? */ + SetLastError(0xdeadbeef); + ret = CryptRetrieveObjectByUrlA(url, CONTEXT_OID_CERTIFICATE, + CRYPT_CACHE_ONLY_RETRIEVAL, 0, (void **)&cert, NULL, NULL, NULL, NULL); + todo_wine + ok(!ret && GetLastError() == ERROR_FILE_NOT_FOUND, + "Expected ERROR_FILE_NOT_FOUND, got %d\n", GetLastError()); +} + START_TEST(cryptnet) { test_getObjectUrl(); + test_retrieveObjectByUrl(); }
1
0
0
0
Juan Lang : cryptnet: Add stubs for CryptRetrieveObjectByUrlA/W.
by Alexandre Julliard
23 Oct '07
23 Oct '07
Module: wine Branch: master Commit: 2fbefb6f75360f2c4dac44a9aa9b502ffa3e49ad URL:
http://source.winehq.org/git/wine.git/?a=commit;h=2fbefb6f75360f2c4dac44a9a…
Author: Juan Lang <juan.lang(a)gmail.com> Date: Mon Oct 22 10:19:00 2007 -0700 cryptnet: Add stubs for CryptRetrieveObjectByUrlA/W. --- dlls/cryptnet/cryptnet.spec | 4 ++-- dlls/cryptnet/cryptnet_main.c | 28 ++++++++++++++++++++++++++++ 2 files changed, 30 insertions(+), 2 deletions(-) diff --git a/dlls/cryptnet/cryptnet.spec b/dlls/cryptnet/cryptnet.spec index bcf35e6..6fca711 100644 --- a/dlls/cryptnet/cryptnet.spec +++ b/dlls/cryptnet/cryptnet.spec @@ -7,8 +7,8 @@ @ stdcall CryptGetObjectUrl(ptr ptr long ptr ptr ptr ptr ptr) @ stub CryptGetTimeValidObject @ stub CryptInstallCancelRetrieval -@ stub CryptRetrieveObjectByUrlA -@ stub CryptRetrieveObjectByUrlW +@ stdcall CryptRetrieveObjectByUrlA(str str long long ptr ptr ptr ptr ptr) +@ stdcall CryptRetrieveObjectByUrlW(wstr str long long ptr ptr ptr ptr ptr) @ stub CryptUninstallCancelRetrieval @ stdcall -private DllRegisterServer() @ stdcall -private DllUnregisterServer() diff --git a/dlls/cryptnet/cryptnet_main.c b/dlls/cryptnet/cryptnet_main.c index 206ba24..0c5843b 100644 --- a/dlls/cryptnet/cryptnet_main.c +++ b/dlls/cryptnet/cryptnet_main.c @@ -291,6 +291,34 @@ BOOL WINAPI CryptGetObjectUrl(LPCSTR pszUrlOid, LPVOID pvPara, DWORD dwFlags, } /*********************************************************************** + * CryptRetrieveObjectByUrlA (CRYPTNET.@) + */ +BOOL WINAPI CryptRetrieveObjectByUrlA(LPCSTR pszURL, LPCSTR pszObjectOid, + DWORD dwRetrievalFlags, DWORD dwTimeout, LPVOID *ppvObject, + HCRYPTASYNC hAsyncRetrieve, PCRYPT_CREDENTIALS pCredentials, LPVOID pvVerify, + PCRYPT_RETRIEVE_AUX_INFO pAuxInfo) +{ + FIXME("(%s, %s, %08x, %d, %p, %p, %p, %p, %p)\n", debugstr_a(pszURL), + debugstr_a(pszObjectOid), dwRetrievalFlags, dwTimeout, ppvObject, + hAsyncRetrieve, pCredentials, pvVerify, pAuxInfo); + return FALSE; +} + +/*********************************************************************** + * CryptRetrieveObjectByUrlW (CRYPTNET.@) + */ +BOOL WINAPI CryptRetrieveObjectByUrlW(LPCWSTR pszURL, LPCSTR pszObjectOid, + DWORD dwRetrievalFlags, DWORD dwTimeout, LPVOID *ppvObject, + HCRYPTASYNC hAsyncRetrieve, PCRYPT_CREDENTIALS pCredentials, LPVOID pvVerify, + PCRYPT_RETRIEVE_AUX_INFO pAuxInfo) +{ + FIXME("(%s, %s, %08x, %d, %p, %p, %p, %p, %p)\n", debugstr_w(pszURL), + debugstr_a(pszObjectOid), dwRetrievalFlags, dwTimeout, ppvObject, + hAsyncRetrieve, pCredentials, pvVerify, pAuxInfo); + return FALSE; +} + +/*********************************************************************** * CertDllVerifyRevocation (CRYPTNET.@) */ BOOL WINAPI CertDllVerifyRevocation(DWORD dwEncodingType, DWORD dwRevType,
1
0
0
0
Juan Lang : wininet: Don't assume lpBuffersIn is not NULL.
by Alexandre Julliard
23 Oct '07
23 Oct '07
Module: wine Branch: master Commit: d857c04c95d6441e2c422161b6af3fb4b4be5275 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=d857c04c95d6441e2c422161b…
Author: Juan Lang <juan.lang(a)gmail.com> Date: Mon Oct 22 10:23:54 2007 -0700 wininet: Don't assume lpBuffersIn is not NULL. --- dlls/wininet/http.c | 9 ++++++--- 1 files changed, 6 insertions(+), 3 deletions(-) diff --git a/dlls/wininet/http.c b/dlls/wininet/http.c index 70239f7..f496733 100644 --- a/dlls/wininet/http.c +++ b/dlls/wininet/http.c @@ -2182,9 +2182,12 @@ BOOL WINAPI HttpSendRequestExW(HINTERNET hRequest, } else { - ret = HTTP_HttpSendRequestW(lpwhr, lpBuffersIn->lpcszHeader, lpBuffersIn->dwHeadersLength, - lpBuffersIn->lpvBuffer, lpBuffersIn->dwBufferLength, - lpBuffersIn->dwBufferTotal, FALSE); + if (lpBuffersIn) + ret = HTTP_HttpSendRequestW(lpwhr, lpBuffersIn->lpcszHeader, lpBuffersIn->dwHeadersLength, + lpBuffersIn->lpvBuffer, lpBuffersIn->dwBufferLength, + lpBuffersIn->dwBufferTotal, FALSE); + else + ret = HTTP_HttpSendRequestW(lpwhr, NULL, 0, NULL, 0, 0, FALSE); } WININET_Release(&lpwhr->hdr);
1
0
0
0
← Newer
1
...
26
27
28
29
30
31
32
...
100
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
88
89
90
91
92
93
94
95
96
97
98
99
100
Results per page:
10
25
50
100
200