ReactOS.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
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
List overview
Download
Ros-diffs
October 2016
----- 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
ros-diffs@reactos.org
20 participants
222 discussions
Start a n
N
ew thread
[akhaldi] 73073: [0.4.3] * Merge eventvwr improvements by Hermès in r73043. CORE-11637
by akhaldi@svn.reactos.org
Author: akhaldi Date: Sat Oct 29 20:41:45 2016 New Revision: 73073 URL:
http://svn.reactos.org/svn/reactos?rev=73073&view=rev
Log: [0.4.3] * Merge eventvwr improvements by Hermès in r73043. CORE-11637 Modified: branches/ros-branch-0_4_3/ (props changed) branches/ros-branch-0_4_3/reactos/ (props changed) branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/eventvwr.c branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/bg-BG.rc branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/cs-CZ.rc branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/de-DE.rc branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/el-GR.rc branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/en-US.rc branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/es-ES.rc branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/fr-FR.rc branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/he-IL.rc branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/it-IT.rc branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/ja-JP.rc branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/ko-KR.rc branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/no-NO.rc branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/pl-PL.rc branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/pt-BR.rc branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/ro-RO.rc branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/ru-RU.rc branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/sk-SK.rc branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/sq-AL.rc branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/sv-SE.rc branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/tr-TR.rc branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/uk-UA.rc branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/zh-CN.rc branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/zh-TW.rc Propchange: branches/ros-branch-0_4_3/ ------------------------------------------------------------------------------ svn:mergeinfo = /trunk:73043 Propchange: branches/ros-branch-0_4_3/reactos/ ------------------------------------------------------------------------------ --- svn:mergeinfo (original) +++ svn:mergeinfo Sat Oct 29 20:41:45 2016 @@ -21,3 +21,4 @@ /branches/usb-bringup:51335,51337,51341-51343,51348,51350,51353,51355,51365-51369,51372,51384-54388,54396-54398,54736-54737,54752-54754,54756-54760,54762,54764-54765,54767-54768,54772,54774-54777,54781,54787,54790-54792,54797-54798,54806,54808,54834-54838,54843,54850,54852,54856,54858-54859 /branches/usb-bringup-trunk:55019-55543,55548-55554,55556-55567 /branches/wlan-bringup:54809-54998 +/trunk/reactos:73043 Modified: branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/eventvwr.c URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/a…
============================================================================== --- branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/eventvwr.c [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/eventvwr.c [iso-8859-1] Sat Oct 29 20:41:45 2016 @@ -29,9 +29,9 @@ #include "eventvwr.h" #include "evtdetctl.h" +#include <sddl.h> // For ConvertSidToStringSidW #include <shellapi.h> #include <shlwapi.h> -#include <strsafe.h> // #include "resource.h" @@ -306,6 +306,10 @@ if (hLibrary == NULL) return NULL; + /* Sanitize dwFlags */ + dwFlags &= ~FORMAT_MESSAGE_FROM_STRING; + dwFlags |= FORMAT_MESSAGE_FROM_HMODULE; + _SEH2_TRY { /* @@ -319,7 +323,7 @@ FORMAT_MESSAGE_IGNORE_INSERTS | FORMAT_MESSAGE_MAX_WIDTH_MASK, */ hLibrary, dwMessageId, - MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), + LANG_USER_DEFAULT, (LPWSTR)&lpMsgBuf, nSize, Arguments); @@ -350,10 +354,10 @@ dwLength = FormatMessageW(dwFlags, hLibrary, dwMessageId, - MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), + LANG_USER_DEFAULT, (LPWSTR)&lpMsgBuf, nSize, - Arguments); + NULL /* Arguments */); } } _SEH2_END; @@ -409,7 +413,7 @@ szDll = wcstok(szMessageDllList, EVENT_DLL_SEPARATOR); while ((szDll != NULL) && !Success) { - // Uses MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT) + // Uses LANG_USER_DEFAULT lpMsgBuf = GetMessageStringFromDll(szDll, dwFlags, dwMessageId, @@ -1261,7 +1265,8 @@ GetEventUserName(IN PEVENTLOGRECORD pelr, OUT PWCHAR pszUser) // TODO: Add IN DWORD BufLen { - PSID lpSid; + PSID pSid; + PWSTR StringSid; WCHAR szName[1024]; WCHAR szDomain[1024]; SID_NAME_USE peUse; @@ -1269,13 +1274,19 @@ DWORD cchDomain = ARRAYSIZE(szDomain); /* Point to the SID */ - lpSid = (PSID)((LPBYTE)pelr + pelr->UserSidOffset); + pSid = (PSID)((LPBYTE)pelr + pelr->UserSidOffset); /* User SID */ if (pelr->UserSidLength > 0) { + /* + * Try to retrieve the user account name and domain name corresponding + * to the SID. If it cannot be retrieved, try to convert the SID to a + * string-form. It should not be bigger than the user-provided buffer + * 'pszUser', otherwise we return an error. + */ if (LookupAccountSidW(NULL, // FIXME: Use computer name? From the particular event? - lpSid, + pSid, szName, &cchName, szDomain, @@ -1284,6 +1295,27 @@ { StringCchCopyW(pszUser, MAX_PATH, szName); return TRUE; + } + else if (ConvertSidToStringSidW(pSid, &StringSid)) + { + BOOL Success; + + /* Copy the string only if the user-provided buffer is small enough */ + if (wcslen(StringSid) + 1 <= MAX_PATH) // + 1 for NULL-terminator + { + StringCchCopyW(pszUser, MAX_PATH, StringSid); + Success = TRUE; + } + else + { + SetLastError(ERROR_NOT_ENOUGH_MEMORY); + Success = FALSE; + } + + /* Free the allocated buffer */ + LocalFree(StringSid); + + return Success; } } @@ -1672,7 +1704,8 @@ sizeof(szStatusText), szStatusBarTemplate, EventLog->LogName, - dwTotalRecords); + dwTotalRecords, + ListView_GetItemCount(hwndListView)); } else { Modified: branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/bg-BG.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/a…
============================================================================== --- branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/bg-BG.rc [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/bg-BG.rc [iso-8859-1] Sat Oct 29 20:41:45 2016 @@ -131,7 +131,7 @@ IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "ÐÑеглед на ÑÑбиÑиÑ" IDS_APP_TITLE_EX "%s - %s Log on \\\\" - IDS_STATUS_MSG "%s has %lu event(s)" + IDS_STATUS_MSG "%s has %lu event(s) (listed: %lu)" IDS_LOADING_WAIT "ÐаÑеждане на ÑÑбиÑиÑÑа. ÐоÑакайÑе..." IDS_NO_ITEMS "There are no items to show in this view." // "No events in this log." IDS_EVENTLOG_SYSTEM "System Logs" Modified: branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/cs-CZ.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/a…
============================================================================== --- branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/cs-CZ.rc [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/cs-CZ.rc [iso-8859-1] Sat Oct 29 20:41:45 2016 @@ -131,7 +131,7 @@ IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "ProhlÞeÄ událostÃ" IDS_APP_TITLE_EX "%s - Protkol %s na \\\\" - IDS_STATUS_MSG "PoÄet událostà v protokolu %s: %lu" + IDS_STATUS_MSG "PoÄet událostà v protokolu %s: %lu (listed: %lu)" IDS_LOADING_WAIT "NaÄÃtám protokol událostÃ. ProsÃm Äekejte..." IDS_NO_ITEMS "There are no items to show in this view." // "No events in this log." IDS_EVENTLOG_SYSTEM "System Logs" Modified: branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/de-DE.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/a…
============================================================================== --- branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/de-DE.rc [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/de-DE.rc [iso-8859-1] Sat Oct 29 20:41:45 2016 @@ -133,7 +133,7 @@ IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "Ereignisanzeige" IDS_APP_TITLE_EX "%s - %s Log on \\\\" - IDS_STATUS_MSG "%s has %lu event(s)" + IDS_STATUS_MSG "%s has %lu event(s) (listed: %lu)" IDS_LOADING_WAIT "Ereignis-Protokolle werden geladen. Bitte warten..." IDS_NO_ITEMS "There are no items to show in this view." // "No events in this log." IDS_EVENTLOG_SYSTEM "System Logs" Modified: branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/el-GR.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/a…
============================================================================== --- branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/el-GR.rc [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/el-GR.rc [iso-8859-1] Sat Oct 29 20:41:45 2016 @@ -133,7 +133,7 @@ IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "Event Viewer" IDS_APP_TITLE_EX "%s - %s Log on \\\\" - IDS_STATUS_MSG "%s has %lu event(s)" + IDS_STATUS_MSG "%s has %lu event(s) (listed: %lu)" IDS_LOADING_WAIT "ÎίνεÏαι ÏÏÏÏÏÏη ÏÏν Logs ÏÏ Î¼Î²Î¬Î½ÏÏν. ΠαÏÎ±ÎºÎ±Î»Ï ÏεÏιμÎνεÏε..." IDS_NO_ITEMS "There are no items to show in this view." // "No events in this log." IDS_EVENTLOG_SYSTEM "System Logs" Modified: branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/en-US.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/a…
============================================================================== --- branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/en-US.rc [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/en-US.rc [iso-8859-1] Sat Oct 29 20:41:45 2016 @@ -139,7 +139,7 @@ IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "Event Viewer" IDS_APP_TITLE_EX "%s - %s Log on \\\\" - IDS_STATUS_MSG "%s has %lu event(s)" + IDS_STATUS_MSG "%s has %lu event(s) (listed: %lu)" IDS_LOADING_WAIT "Loading Event Logs. Please wait..." IDS_NO_ITEMS "There are no items to show in this view." // "No events in this log." IDS_EVENTLOG_SYSTEM "System Logs" Modified: branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/es-ES.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/a…
============================================================================== --- branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/es-ES.rc [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/es-ES.rc [iso-8859-1] Sat Oct 29 20:41:45 2016 @@ -133,7 +133,7 @@ IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "Visor de eventos" IDS_APP_TITLE_EX "%s - Registro de %s en \\\\" - IDS_STATUS_MSG "%s tiene %lu evento(s)" + IDS_STATUS_MSG "%s tiene %lu evento(s) (listed: %lu)" IDS_LOADING_WAIT "Recuperando eventos. Espere un momento..." IDS_NO_ITEMS "There are no items to show in this view." // "No events in this log." IDS_EVENTLOG_SYSTEM "System Logs" Modified: branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/fr-FR.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/a…
============================================================================== --- branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/fr-FR.rc [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/fr-FR.rc [iso-8859-1] Sat Oct 29 20:41:45 2016 @@ -133,7 +133,7 @@ IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "Visionneuse d'événements" IDS_APP_TITLE_EX "%s - Journal %s sur \\\\" - IDS_STATUS_MSG "%s contient %lu événement(s)" + IDS_STATUS_MSG "%s contient %lu événement(s) (listés : %lu)" IDS_LOADING_WAIT "Chargement des journaux d'événements. Veuillez patienter..." IDS_NO_ITEMS "Aucun élément à afficher dans cet aperçu." // "No events in this log." IDS_EVENTLOG_SYSTEM "Journaux système" Modified: branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/he-IL.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/a…
============================================================================== --- branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/he-IL.rc [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/he-IL.rc [iso-8859-1] Sat Oct 29 20:41:45 2016 @@ -133,7 +133,7 @@ IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "×××× ×××ר××¢××" IDS_APP_TITLE_EX "%s - %s Log on \\\\" - IDS_STATUS_MSG "%s has %lu event(s)" + IDS_STATUS_MSG "%s has %lu event(s) (listed: %lu)" IDS_LOADING_WAIT "×××¢× ×××× × ××ר××¢××, × × ×××ת××..." IDS_NO_ITEMS "There are no items to show in this view." // "No events in this log." IDS_EVENTLOG_SYSTEM "System Logs" Modified: branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/it-IT.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/a…
============================================================================== --- branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/it-IT.rc [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/it-IT.rc [iso-8859-1] Sat Oct 29 20:41:45 2016 @@ -133,7 +133,7 @@ IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "Visualizzatore eventi" IDS_APP_TITLE_EX "%s - %s Log on \\\\" - IDS_STATUS_MSG "%s has %lu event(s)" + IDS_STATUS_MSG "%s has %lu event(s) (listed: %lu)" IDS_LOADING_WAIT "Caricamento eventi in corso. Attendere..." IDS_NO_ITEMS "There are no items to show in this view." // "No events in this log." IDS_EVENTLOG_SYSTEM "System Logs" Modified: branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/ja-JP.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/a…
============================================================================== --- branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/ja-JP.rc [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/ja-JP.rc [iso-8859-1] Sat Oct 29 20:41:45 2016 @@ -133,7 +133,7 @@ IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "ã¤ãã³ã ãã¥ã¼ã¢" IDS_APP_TITLE_EX "%s - %s Log on \\\\" - IDS_STATUS_MSG "%s has %lu event(s)" + IDS_STATUS_MSG "%s has %lu event(s) (listed: %lu)" IDS_LOADING_WAIT "ã¤ãã³ã ãã°ãèªã¿è¾¼ãã§ãã¾ãã ãå¾ ã¡ãã ãã..." IDS_NO_ITEMS "There are no items to show in this view." // "No events in this log." IDS_EVENTLOG_SYSTEM "System Logs" Modified: branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/ko-KR.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/a…
============================================================================== --- branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/ko-KR.rc [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/ko-KR.rc [iso-8859-1] Sat Oct 29 20:41:45 2016 @@ -133,7 +133,7 @@ IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "ì´ë²¤í¸ ë·°ì´" IDS_APP_TITLE_EX "%s - %s Log on \\\\" - IDS_STATUS_MSG "%s has %lu event(s)" + IDS_STATUS_MSG "%s has %lu event(s) (listed: %lu)" IDS_LOADING_WAIT "ì´ë²¤í¸ ë¡ê·¸ ë¡ë©ì¤. 기ë¤ë ¤ì£¼ì¸ì..." IDS_NO_ITEMS "There are no items to show in this view." // "No events in this log." IDS_EVENTLOG_SYSTEM "System Logs" Modified: branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/no-NO.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/a…
============================================================================== --- branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/no-NO.rc [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/no-NO.rc [iso-8859-1] Sat Oct 29 20:41:45 2016 @@ -131,7 +131,7 @@ IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "Hendelseliste" IDS_APP_TITLE_EX "%s - %s Log on \\\\" - IDS_STATUS_MSG "%s has %lu event(s)" + IDS_STATUS_MSG "%s has %lu event(s) (listed: %lu)" IDS_LOADING_WAIT "Laster Hendelseliste. Venligst vent..." IDS_NO_ITEMS "There are no items to show in this view." // "No events in this log." IDS_EVENTLOG_SYSTEM "System Logs" Modified: branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/pl-PL.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/a…
============================================================================== --- branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/pl-PL.rc [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/pl-PL.rc [iso-8859-1] Sat Oct 29 20:41:45 2016 @@ -135,7 +135,7 @@ IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "PodglÄ d zdarzeÅ" IDS_APP_TITLE_EX "%s - %s Log na \\\\" - IDS_STATUS_MSG "%s posiada %lu zdarzeÅ" + IDS_STATUS_MSG "%s posiada %lu zdarzeÅ (listed: %lu)" IDS_LOADING_WAIT "Åadowanie logów zdarzeÅ. ProszÄ czekaÄ..." IDS_NO_ITEMS "There are no items to show in this view." // "No events in this log." IDS_EVENTLOG_SYSTEM "System Logs" Modified: branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/pt-BR.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/a…
============================================================================== --- branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/pt-BR.rc [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/pt-BR.rc [iso-8859-1] Sat Oct 29 20:41:45 2016 @@ -133,7 +133,7 @@ IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "Visualizador de Eventos" IDS_APP_TITLE_EX "%s - %s Log on \\\\" - IDS_STATUS_MSG "%s has %lu event(s)" + IDS_STATUS_MSG "%s has %lu event(s) (listed: %lu)" IDS_LOADING_WAIT "Carregando Registros de Eventos. Por favor aguarde..." IDS_NO_ITEMS "There are no items to show in this view." // "No events in this log." IDS_EVENTLOG_SYSTEM "System Logs" Modified: branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/ro-RO.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/a…
============================================================================== --- branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/ro-RO.rc [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/ro-RO.rc [iso-8859-1] Sat Oct 29 20:41:45 2016 @@ -136,7 +136,7 @@ IDS_COPYRIGHT "Drept de autor (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "Observator de evenimente" IDS_APP_TITLE_EX "%s - %s autentificat pe \\\\" - IDS_STATUS_MSG "%s are %lu eveniment(e)" + IDS_STATUS_MSG "%s are %lu eveniment(e) (listed: %lu)" IDS_LOADING_WAIT "Se încarcÄ jurnalul de evenimentele. AÈteptaÈiâ¦" IDS_NO_ITEMS "There are no items to show in this view." // "No events in this log." IDS_EVENTLOG_SYSTEM "System Logs" Modified: branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/ru-RU.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/a…
============================================================================== --- branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/ru-RU.rc [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/ru-RU.rc [iso-8859-1] Sat Oct 29 20:41:45 2016 @@ -133,7 +133,7 @@ IDS_COPYRIGHT "ÐвÑоÑÑкие пÑава (С) 2007 ÐаÑк ÐиÑлаÑÑ (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "ÐÑоÑмоÑÑ ÑобÑÑий" IDS_APP_TITLE_EX "%s - %s жÑÑнал на \\\\" - IDS_STATUS_MSG "%s ÑодеÑÐ¶Ð¸Ñ %lu ÑобÑÑие (ий)" + IDS_STATUS_MSG "%s ÑодеÑÐ¶Ð¸Ñ %lu ÑобÑÑие(ий) (listed: %lu)" IDS_LOADING_WAIT "ÐÐ´ÐµÑ Ð·Ð°Ð³ÑÑзка. ÐодождиÑе..." IDS_NO_ITEMS "ÐÐµÑ ÑлеменÑов Ð´Ð»Ñ Ð¾ÑобÑÐ°Ð¶ÐµÐ½Ð¸Ñ Ð² ÑÑом пÑедÑÑавлении." // "No events in this log." IDS_EVENTLOG_SYSTEM "СиÑÑемнÑй жÑÑнал" Modified: branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/sk-SK.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/a…
============================================================================== --- branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/sk-SK.rc [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/sk-SK.rc [iso-8859-1] Sat Oct 29 20:41:45 2016 @@ -136,7 +136,7 @@ IDS_COPYRIGHT "Autorské práva (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "ZobrazovaÄ udalostÃ" IDS_APP_TITLE_EX "%s - %s Log on \\\\" - IDS_STATUS_MSG "%s has %lu event(s)" + IDS_STATUS_MSG "%s has %lu event(s) (listed: %lu)" IDS_LOADING_WAIT "Nahrávam záznamy s udalosÅ¥ami. PoÄkajte, prosÃm..." IDS_NO_ITEMS "There are no items to show in this view." // "No events in this log." IDS_EVENTLOG_SYSTEM "System Logs" Modified: branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/sq-AL.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/a…
============================================================================== --- branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/sq-AL.rc [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/sq-AL.rc [iso-8859-1] Sat Oct 29 20:41:45 2016 @@ -139,7 +139,7 @@ IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "Shikues ngjarjesh" IDS_APP_TITLE_EX "%s - %s Log on \\\\" - IDS_STATUS_MSG "%s has %lu event(s)" + IDS_STATUS_MSG "%s has %lu event(s) (listed: %lu)" IDS_LOADING_WAIT "Ngarkim loget e ngjarjeve. Ju lutem prisni..." IDS_NO_ITEMS "There are no items to show in this view." // "No events in this log." IDS_EVENTLOG_SYSTEM "System Logs" Modified: branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/sv-SE.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/a…
============================================================================== --- branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/sv-SE.rc [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/sv-SE.rc [iso-8859-1] Sat Oct 29 20:41:45 2016 @@ -133,7 +133,7 @@ IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "Händelselogg" IDS_APP_TITLE_EX "%s - %s Log on \\\\" - IDS_STATUS_MSG "%s has %lu event(s)" + IDS_STATUS_MSG "%s has %lu event(s) (listed: %lu)" IDS_LOADING_WAIT "Laddar in Händelseloggen. Vänligen vänta..." IDS_NO_ITEMS "There are no items to show in this view." // "No events in this log." IDS_EVENTLOG_SYSTEM "System Logs" Modified: branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/tr-TR.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/a…
============================================================================== --- branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/tr-TR.rc [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/tr-TR.rc [iso-8859-1] Sat Oct 29 20:41:45 2016 @@ -139,7 +139,7 @@ IDS_COPYRIGHT "Telif Hakkı: 2007 - Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "Olay Görüntüleyicisi" IDS_APP_TITLE_EX "%s - %s Oturum Aç \\\\" - IDS_STATUS_MSG "%s -> %lu olay var." + IDS_STATUS_MSG "%s -> %lu olay var (listed: %lu)" IDS_LOADING_WAIT "Olay kayıtları yükleniyor. Lütfen bekleyiniz..." IDS_NO_ITEMS "Bu görünümde görüntülenecek bir öÄe bile yok." // "No events in this log." IDS_EVENTLOG_SYSTEM "Dizge Kayıtları" Modified: branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/uk-UA.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/a…
============================================================================== --- branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/uk-UA.rc [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/uk-UA.rc [iso-8859-1] Sat Oct 29 20:41:45 2016 @@ -133,7 +133,7 @@ IDS_COPYRIGHT "Copyright (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "ÐглÑÐ´Ð°Ñ Ð¿Ð¾Ð´Ñй" IDS_APP_TITLE_EX "%s - %s Log on \\\\" - IDS_STATUS_MSG "%s has %lu event(s)" + IDS_STATUS_MSG "%s has %lu event(s) (listed: %lu)" IDS_LOADING_WAIT "ÐаванÑÐ°Ð¶ÐµÐ½Ð½Ñ ÐвÑÑÑ Ð¿Ð¾Ð´Ñй. ÐÑÐ´Ñ Ð»Ð°Ñка, заÑекайÑе..." IDS_NO_ITEMS "There are no items to show in this view." // "No events in this log." IDS_EVENTLOG_SYSTEM "System Logs" Modified: branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/zh-CN.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/a…
============================================================================== --- branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/zh-CN.rc [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/zh-CN.rc [iso-8859-1] Sat Oct 29 20:41:45 2016 @@ -133,7 +133,7 @@ IDS_COPYRIGHT "çæææ (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "äºä»¶æ¥çå¨" IDS_APP_TITLE_EX "%s - %s Log on \\\\" - IDS_STATUS_MSG "%s has %lu event(s)" + IDS_STATUS_MSG "%s has %lu event(s) (listed: %lu)" IDS_LOADING_WAIT "æ£å¨è½½å ¥æ¥å¿ã请ç¨å..." IDS_NO_ITEMS "There are no items to show in this view." // "No events in this log." IDS_EVENTLOG_SYSTEM "System Logs" Modified: branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/zh-TW.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/a…
============================================================================== --- branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/zh-TW.rc [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/base/applications/mscutils/eventvwr/lang/zh-TW.rc [iso-8859-1] Sat Oct 29 20:41:45 2016 @@ -133,7 +133,7 @@ IDS_COPYRIGHT "çæ¬ææ (C) 2007 Marc Piulachs (marc.piulachs(a)codexchange.net)" IDS_APP_TITLE "äºä»¶æª¢è¦å¨" IDS_APP_TITLE_EX "%s - %s Log on \\\\" - IDS_STATUS_MSG "%s has %lu event(s)" + IDS_STATUS_MSG "%s has %lu event(s) (listed: %lu)" IDS_LOADING_WAIT "æ£å¨è¼å ¥æ¥èªã è«ç¨å..." IDS_NO_ITEMS "There are no items to show in this view." // "No events in this log." IDS_EVENTLOG_SYSTEM "System Logs"
8 years, 1 month
1
0
0
0
[tfaber] 73072: [FASTFAT] - Only lock down the user buffer in the non-cached read/write case. CcCopyRead/CcCopyWrite takes care of this in the cached case, and does not impose a size limit like an ...
by tfaber@svn.reactos.org
Author: tfaber Date: Sat Oct 29 20:30:49 2016 New Revision: 73072 URL:
http://svn.reactos.org/svn/reactos?rev=73072&view=rev
Log: [FASTFAT] - Only lock down the user buffer in the non-cached read/write case. CcCopyRead/CcCopyWrite takes care of this in the cached case, and does not impose a size limit like an MDL does. CORE-12132 #resolve Modified: trunk/reactos/drivers/filesystems/fastfat/rw.c Modified: trunk/reactos/drivers/filesystems/fastfat/rw.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/filesystems/fastfa…
============================================================================== --- trunk/reactos/drivers/filesystems/fastfat/rw.c [iso-8859-1] (original) +++ trunk/reactos/drivers/filesystems/fastfat/rw.c [iso-8859-1] Sat Oct 29 20:30:49 2016 @@ -656,11 +656,6 @@ } Buffer = VfatGetUserBuffer(IrpContext->Irp, BooleanFlagOn(IrpContext->Irp->Flags, IRP_PAGING_IO)); - Status = VfatLockUserBuffer(IrpContext->Irp, Length, IoWriteAccess); - if (!NT_SUCCESS(Status)) - { - goto ByeBye; - } if (!(IrpContext->Irp->Flags & (IRP_NOCACHE|IRP_PAGING_IO)) && !(Fcb->Flags & (FCB_IS_PAGE_FILE|FCB_IS_VOLUME))) @@ -711,6 +706,12 @@ else { // non cached read + Status = VfatLockUserBuffer(IrpContext->Irp, Length, IoWriteAccess); + if (!NT_SUCCESS(Status)) + { + goto ByeBye; + } + if (ByteOffset.QuadPart + Length > ROUND_UP_64(Fcb->RFCB.FileSize.QuadPart, BytesPerSector)) { Length = (ULONG)(ROUND_UP_64(Fcb->RFCB.FileSize.QuadPart, BytesPerSector) - ByteOffset.QuadPart); @@ -921,12 +922,6 @@ } Buffer = VfatGetUserBuffer(IrpContext->Irp, BooleanFlagOn(IrpContext->Irp->Flags, IRP_PAGING_IO)); - Status = VfatLockUserBuffer(IrpContext->Irp, Length, IoReadAccess); - if (!NT_SUCCESS(Status)) - { - Status = STATUS_INVALID_USER_BUFFER; - goto ByeBye; - } if (!(Fcb->Flags & (FCB_IS_FAT|FCB_IS_VOLUME)) && !(IrpContext->Irp->Flags & IRP_PAGING_IO) && @@ -987,6 +982,12 @@ else { // non cached write + Status = VfatLockUserBuffer(IrpContext->Irp, Length, IoReadAccess); + if (!NT_SUCCESS(Status)) + { + Status = STATUS_INVALID_USER_BUFFER; + goto ByeBye; + } if (ByteOffset.QuadPart > OldFileSize.QuadPart) {
8 years, 1 month
1
0
0
0
[tfaber] 73071: [NTDLL_APITEST] - Add a test for NtReadFile, also covering buffer size too large for an MDL CORE-12132
by tfaber@svn.reactos.org
Author: tfaber Date: Sat Oct 29 20:14:16 2016 New Revision: 73071 URL:
http://svn.reactos.org/svn/reactos?rev=73071&view=rev
Log: [NTDLL_APITEST] - Add a test for NtReadFile, also covering buffer size too large for an MDL CORE-12132 Added: trunk/rostests/apitests/ntdll/NtReadFile.c - copied, changed from r73059, trunk/rostests/apitests/ntdll/NtWriteFile.c Modified: trunk/rostests/apitests/ntdll/CMakeLists.txt trunk/rostests/apitests/ntdll/testlist.c Modified: trunk/rostests/apitests/ntdll/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/ntdll/CMakeLists…
============================================================================== --- trunk/rostests/apitests/ntdll/CMakeLists.txt [iso-8859-1] (original) +++ trunk/rostests/apitests/ntdll/CMakeLists.txt [iso-8859-1] Sat Oct 29 20:14:16 2016 @@ -18,6 +18,7 @@ NtQueryKey.c NtQuerySystemEnvironmentValue.c NtQueryVolumeInformationFile.c + NtReadFile.c NtSaveKey.c NtSetValueKey.c NtWriteFile.c Copied: trunk/rostests/apitests/ntdll/NtReadFile.c (from r73059, trunk/rostests/apitests/ntdll/NtWriteFile.c) URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/ntdll/NtReadFile…
============================================================================== --- trunk/rostests/apitests/ntdll/NtWriteFile.c [iso-8859-1] (original) +++ trunk/rostests/apitests/ntdll/NtReadFile.c [iso-8859-1] Sat Oct 29 20:14:16 2016 @@ -1,7 +1,7 @@ /* * PROJECT: ReactOS API tests * LICENSE: LGPLv2.1+ - See COPYING.LIB in the top level directory - * PURPOSE: Test for NtWriteFile + * PURPOSE: Test for NtReadFile * PROGRAMMER: Thomas Faber <thomas.faber(a)reactos.org> */ @@ -47,11 +47,11 @@ return Is64BitSystem() ? 48 : 28; } -START_TEST(NtWriteFile) +START_TEST(NtReadFile) { NTSTATUS Status; HANDLE FileHandle; - UNICODE_STRING FileName = RTL_CONSTANT_STRING(L"\\SystemRoot\\ntdll-apitest-NtWriteFile-test.bin"); + UNICODE_STRING FileName = RTL_CONSTANT_STRING(L"\\SystemRoot\\ntdll-apitest-NtReadFile-test.bin"); PVOID Buffer; SIZE_T BufferSize; LARGE_INTEGER ByteOffset; @@ -73,7 +73,7 @@ 0, &BufferSize, MEM_RESERVE | MEM_COMMIT, - PAGE_READONLY); + PAGE_READWRITE); if (!NT_SUCCESS(Status)) { skip("Failed to allocate memory, status %lx\n", Status); @@ -86,7 +86,7 @@ NULL, NULL); Status = NtCreateFile(&FileHandle, - FILE_WRITE_DATA | DELETE | SYNCHRONIZE, + FILE_READ_DATA | FILE_WRITE_DATA | DELETE | SYNCHRONIZE, &ObjectAttributes, &IoStatus, NULL, @@ -99,53 +99,66 @@ 0); ok_hex(Status, STATUS_SUCCESS); - /* non-cached, max size -- succeeds */ + ByteOffset.QuadPart = 0x10000; Status = NtWriteFile(FileHandle, NULL, NULL, NULL, &IoStatus, Buffer, - LargeMdlMaxDataSize - PAGE_SIZE, + BufferSize - 0x10000, &ByteOffset, NULL); ok_hex(Status, STATUS_SUCCESS); + ByteOffset.QuadPart = 0; /* non-cached, max size -- succeeds */ - Status = NtWriteFile(FileHandle, - NULL, - NULL, - NULL, - &IoStatus, - Buffer, - LargeMdlMaxDataSize, - &ByteOffset, - NULL); + Status = NtReadFile(FileHandle, + NULL, + NULL, + NULL, + &IoStatus, + Buffer, + LargeMdlMaxDataSize - PAGE_SIZE, + &ByteOffset, + NULL); + ok_hex(Status, STATUS_SUCCESS); + + /* non-cached, max size -- succeeds */ + Status = NtReadFile(FileHandle, + NULL, + NULL, + NULL, + &IoStatus, + Buffer, + LargeMdlMaxDataSize, + &ByteOffset, + NULL); ok_hex(Status, STATUS_SUCCESS); /* non-cached, too large -- fails to allocate MDL * Note: this returns STATUS_SUCCESS on Win7 -- higher MDL size limit */ - Status = NtWriteFile(FileHandle, - NULL, - NULL, - NULL, - &IoStatus, - Buffer, - LargeMdlMaxDataSize + PAGE_SIZE, - &ByteOffset, - NULL); + Status = NtReadFile(FileHandle, + NULL, + NULL, + NULL, + &IoStatus, + Buffer, + LargeMdlMaxDataSize + PAGE_SIZE, + &ByteOffset, + NULL); ok_hex(Status, STATUS_INSUFFICIENT_RESOURCES); /* non-cached, unaligned -- fails with invalid parameter */ - Status = NtWriteFile(FileHandle, - NULL, - NULL, - NULL, - &IoStatus, - Buffer, - LargeMdlMaxDataSize + 1, - &ByteOffset, - NULL); + Status = NtReadFile(FileHandle, + NULL, + NULL, + NULL, + &IoStatus, + Buffer, + LargeMdlMaxDataSize + 1, + &ByteOffset, + NULL); ok_hex(Status, STATUS_INVALID_PARAMETER); DispositionInfo.DeleteFile = TRUE; @@ -159,7 +172,7 @@ ok_hex(Status, STATUS_SUCCESS); Status = NtCreateFile(&FileHandle, - FILE_WRITE_DATA | DELETE | SYNCHRONIZE, + FILE_READ_DATA | FILE_WRITE_DATA | DELETE | SYNCHRONIZE, &ObjectAttributes, &IoStatus, NULL, @@ -171,38 +184,51 @@ 0); ok_hex(Status, STATUS_SUCCESS); - /* cached: succeeds with arbitrary length */ + ByteOffset.QuadPart = 0x10000; Status = NtWriteFile(FileHandle, NULL, NULL, NULL, &IoStatus, Buffer, - LargeMdlMaxDataSize, + BufferSize - 0x10000, &ByteOffset, NULL); ok_hex(Status, STATUS_SUCCESS); - - Status = NtWriteFile(FileHandle, - NULL, - NULL, - NULL, - &IoStatus, - Buffer, - LargeMdlMaxDataSize + 1, - &ByteOffset, - NULL); - ok_hex(Status, STATUS_SUCCESS); - - Status = NtWriteFile(FileHandle, - NULL, - NULL, - NULL, - &IoStatus, - Buffer, - TooLargeDataSize, - &ByteOffset, - NULL); + ByteOffset.QuadPart = 0; + + /* cached: succeeds with arbitrary length */ + Status = NtReadFile(FileHandle, + NULL, + NULL, + NULL, + &IoStatus, + Buffer, + LargeMdlMaxDataSize, + &ByteOffset, + NULL); + ok_hex(Status, STATUS_SUCCESS); + + Status = NtReadFile(FileHandle, + NULL, + NULL, + NULL, + &IoStatus, + Buffer, + LargeMdlMaxDataSize + 1, + &ByteOffset, + NULL); + ok_hex(Status, STATUS_SUCCESS); + + Status = NtReadFile(FileHandle, + NULL, + NULL, + NULL, + &IoStatus, + Buffer, + TooLargeDataSize, + &ByteOffset, + NULL); ok_hex(Status, STATUS_SUCCESS); DispositionInfo.DeleteFile = TRUE; Modified: trunk/rostests/apitests/ntdll/testlist.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/ntdll/testlist.c…
============================================================================== --- trunk/rostests/apitests/ntdll/testlist.c [iso-8859-1] (original) +++ trunk/rostests/apitests/ntdll/testlist.c [iso-8859-1] Sat Oct 29 20:14:16 2016 @@ -21,6 +21,7 @@ extern void func_NtQueryKey(void); extern void func_NtQuerySystemEnvironmentValue(void); extern void func_NtQueryVolumeInformationFile(void); +extern void func_NtReadFile(void); extern void func_NtSaveKey(void); extern void func_NtSetValueKey(void); extern void func_NtSystemInformation(void); @@ -68,6 +69,7 @@ { "NtQueryKey", func_NtQueryKey }, { "NtQuerySystemEnvironmentValue", func_NtQuerySystemEnvironmentValue }, { "NtQueryVolumeInformationFile", func_NtQueryVolumeInformationFile }, + { "NtReadFile", func_NtReadFile }, { "NtSaveKey", func_NtSaveKey}, { "NtSetValueKey", func_NtSetValueKey}, { "NtSystemInformation", func_NtSystemInformation },
8 years, 1 month
1
0
0
0
[phater] 73070: [MSAFD] Implement async connect CORE-12152 #resolve
by phater@svn.reactos.org
Author: phater Date: Sat Oct 29 18:38:27 2016 New Revision: 73070 URL:
http://svn.reactos.org/svn/reactos?rev=73070&view=rev
Log: [MSAFD] Implement async connect CORE-12152 #resolve Modified: trunk/reactos/dll/win32/msafd/misc/dllmain.c trunk/reactos/dll/win32/msafd/msafd.h Modified: trunk/reactos/dll/win32/msafd/misc/dllmain.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msafd/misc/dllma…
============================================================================== --- trunk/reactos/dll/win32/msafd/misc/dllmain.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/msafd/misc/dllmain.c [iso-8859-1] Sat Oct 29 18:38:27 2016 @@ -1719,6 +1719,46 @@ return AcceptSocket; } +VOID +NTAPI +AfdConnectAPC(PVOID ApcContext, + PIO_STATUS_BLOCK IoStatusBlock, + ULONG Reserved) +{ + PAFDCONNECTAPCCONTEXT Context = ApcContext; + + if (IoStatusBlock->Status == STATUS_SUCCESS) + { + Context->lpSocket->SharedData->State = SocketConnected; + Context->lpSocket->TdiConnectionHandle = (HANDLE)IoStatusBlock->Information; + } + + if (Context->lpConnectInfo) HeapFree(GetProcessHeap(), 0, Context->lpConnectInfo); + + /* Re-enable Async Event */ + SockReenableAsyncSelectEvent(Context->lpSocket, FD_WRITE); + + /* FIXME: THIS IS NOT RIGHT!!! HACK HACK HACK! */ + SockReenableAsyncSelectEvent(Context->lpSocket, FD_CONNECT); + + if (IoStatusBlock->Status == STATUS_SUCCESS && (Context->lpSocket->HelperEvents & WSH_NOTIFY_CONNECT)) + { + Context->lpSocket->HelperData->WSHNotify(Context->lpSocket->HelperContext, + Context->lpSocket->Handle, + Context->lpSocket->TdiAddressHandle, + Context->lpSocket->TdiConnectionHandle, + WSH_NOTIFY_CONNECT); + } + else if (IoStatusBlock->Status != STATUS_SUCCESS && (Context->lpSocket->HelperEvents & WSH_NOTIFY_CONNECT_ERROR)) + { + Context->lpSocket->HelperData->WSHNotify(Context->lpSocket->HelperContext, + Context->lpSocket->Handle, + Context->lpSocket->TdiAddressHandle, + Context->lpSocket->TdiConnectionHandle, + WSH_NOTIFY_CONNECT_ERROR); + } + HeapFree(GlobalHeap, 0, ApcContext); +} int WSPAPI WSPConnect(SOCKET Handle, @@ -1741,6 +1781,18 @@ PSOCKADDR BindAddress; HANDLE SockEvent; int SocketDataLength; + PVOID APCContext = NULL; + PVOID APCFunction = NULL; + + TRACE("Called\n"); + + /* Get the Socket Structure associate to this Socket*/ + Socket = GetSocketStructure(Handle); + if (!Socket) + { + if (lpErrno) *lpErrno = WSAENOTSOCK; + return SOCKET_ERROR; + } Status = NtCreateEvent(&SockEvent, EVENT_ALL_ACCESS, @@ -1750,17 +1802,6 @@ if (!NT_SUCCESS(Status)) return MsafdReturnWithErrno(Status, lpErrno, 0, NULL); - - TRACE("Called\n"); - - /* Get the Socket Structure associate to this Socket*/ - Socket = GetSocketStructure(Handle); - if (!Socket) - { - NtClose(SockEvent); - if (lpErrno) *lpErrno = WSAENOTSOCK; - return SOCKET_ERROR; - } /* Bind us First */ if (Socket->SharedData->State == SocketOpen) @@ -1872,14 +1913,22 @@ /* FIXME: Handle Async Connect */ if (Socket->SharedData->NonBlocking) { - ERR("Async Connect UNIMPLEMENTED!\n"); + APCFunction = &AfdConnectAPC; // should be a private io completition function inside us + APCContext = HeapAlloc(GlobalHeap, 0, sizeof(AFDCONNECTAPCCONTEXT)); + if (!APCContext) + { + ERR("Not enough memory for APC Context\n"); + return MsafdReturnWithErrno(STATUS_INSUFFICIENT_RESOURCES, lpErrno, 0, NULL); + } + ((PAFDCONNECTAPCCONTEXT)APCContext)->lpConnectInfo = ConnectInfo; + ((PAFDCONNECTAPCCONTEXT)APCContext)->lpSocket = Socket; } /* Send IOCTL */ Status = NtDeviceIoControlFile((HANDLE)Handle, SockEvent, - NULL, - NULL, + APCFunction, + APCContext, &IOSB, IOCTL_AFD_CONNECT, ConnectInfo, @@ -1887,11 +1936,19 @@ NULL, 0); /* Wait for return */ - if (Status == STATUS_PENDING) + if (Status == STATUS_PENDING && !Socket->SharedData->NonBlocking) { WaitForSingleObject(SockEvent, INFINITE); Status = IOSB.Status; } + + if (Status == STATUS_PENDING) + { + TRACE("Leaving (Pending)\n"); + return MsafdReturnWithErrno(STATUS_CANT_WAIT, lpErrno, 0, NULL); + } + + if (APCContext) HeapFree(GetProcessHeap(), 0, APCContext); if (Status != STATUS_SUCCESS) goto notify; Modified: trunk/reactos/dll/win32/msafd/msafd.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msafd/msafd.h?re…
============================================================================== --- trunk/reactos/dll/win32/msafd/msafd.h [iso-8859-1] (original) +++ trunk/reactos/dll/win32/msafd/msafd.h [iso-8859-1] Sat Oct 29 18:38:27 2016 @@ -135,6 +135,12 @@ PSOCKET_INFORMATION lpSocket; } AFDAPCCONTEXT, *PAFDAPCCONTEXT; +typedef struct _AFDCONNECTAPCCONTEXT +{ + PAFD_CONNECT_INFO lpConnectInfo; + PSOCKET_INFORMATION lpSocket; +} AFDCONNECTAPCCONTEXT, *PAFDCONNECTAPCCONTEXT; + SOCKET WSPAPI WSPAccept(
8 years, 1 month
1
0
0
0
[akhaldi] 73069: [0.4.3] * Apply the patch that allows us to dynamically change the resolution by resizing in VirtualBox. CORE-6742
by akhaldi@svn.reactos.org
Author: akhaldi Date: Sat Oct 29 18:25:32 2016 New Revision: 73069 URL:
http://svn.reactos.org/svn/reactos?rev=73069&view=rev
Log: [0.4.3] * Apply the patch that allows us to dynamically change the resolution by resizing in VirtualBox. CORE-6742 Modified: branches/ros-branch-0_4_3/reactos/win32ss/gdi/eng/device.c branches/ros-branch-0_4_3/reactos/win32ss/gdi/eng/device.h branches/ros-branch-0_4_3/reactos/win32ss/gdi/eng/pdevobj.c branches/ros-branch-0_4_3/reactos/win32ss/user/ntuser/display.c Modified: branches/ros-branch-0_4_3/reactos/win32ss/gdi/eng/device.c URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/win32s…
============================================================================== --- branches/ros-branch-0_4_3/reactos/win32ss/gdi/eng/device.c [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/win32ss/gdi/eng/device.c [iso-8859-1] Sat Oct 29 18:25:32 2016 @@ -30,99 +30,22 @@ return STATUS_SUCCESS; } - -PGRAPHICS_DEVICE -NTAPI -EngpRegisterGraphicsDevice( - _In_ PUNICODE_STRING pustrDeviceName, - _In_ PUNICODE_STRING pustrDiplayDrivers, - _In_ PUNICODE_STRING pustrDescription, +BOOLEAN +EngpPopulateDeviceModeList( + _Inout_ PGRAPHICS_DEVICE pGraphicsDevice, _In_ PDEVMODEW pdmDefault) { - PGRAPHICS_DEVICE pGraphicsDevice; - PDEVICE_OBJECT pDeviceObject; - PFILE_OBJECT pFileObject; - NTSTATUS Status; PWSTR pwsz; - ULONG i, cj, cModes = 0; - SIZE_T cjWritten; - BOOL bEnable = TRUE; + PLDEVOBJ pldev; PDEVMODEINFO pdminfo; PDEVMODEW pdm, pdmEnd; - PLDEVOBJ pldev; + ULONG i, cModes = 0; BOOLEAN bModeMatch = FALSE; - TRACE("EngpRegisterGraphicsDevice(%wZ)\n", pustrDeviceName); - - /* Allocate a GRAPHICS_DEVICE structure */ - pGraphicsDevice = ExAllocatePoolWithTag(PagedPool, - sizeof(GRAPHICS_DEVICE), - GDITAG_GDEVICE); - if (!pGraphicsDevice) - { - ERR("ExAllocatePoolWithTag failed\n"); - return NULL; - } - - /* Try to open the driver */ - Status = IoGetDeviceObjectPointer(pustrDeviceName, - FILE_READ_DATA | FILE_WRITE_DATA, - &pFileObject, - &pDeviceObject); - if (!NT_SUCCESS(Status)) - { - ERR("Could not open driver %wZ, 0x%lx\n", pustrDeviceName, Status); - ExFreePoolWithTag(pGraphicsDevice, GDITAG_GDEVICE); - return NULL; - } - - /* Enable the device */ - EngFileWrite(pFileObject, &bEnable, sizeof(BOOL), &cjWritten); - - /* Copy the device and file object pointers */ - pGraphicsDevice->DeviceObject = pDeviceObject; - pGraphicsDevice->FileObject = pFileObject; - - /* Copy device name */ - RtlStringCbCopyNW(pGraphicsDevice->szNtDeviceName, - sizeof(pGraphicsDevice->szNtDeviceName), - pustrDeviceName->Buffer, - pustrDeviceName->Length); - - /* Create a win device name (FIXME: virtual devices!) */ - swprintf(pGraphicsDevice->szWinDeviceName, L"\\\\.\\DISPLAY%d", (int)giDevNum); - - /* Allocate a buffer for the strings */ - cj = pustrDiplayDrivers->Length + pustrDescription->Length + sizeof(WCHAR); - pwsz = ExAllocatePoolWithTag(PagedPool, cj, GDITAG_DRVSUP); - if (!pwsz) - { - ERR("Could not allocate string buffer\n"); - ASSERT(FALSE); // FIXME - ExFreePoolWithTag(pGraphicsDevice, GDITAG_GDEVICE); - return NULL; - } - - /* Copy display driver names */ - pGraphicsDevice->pDiplayDrivers = pwsz; - RtlCopyMemory(pGraphicsDevice->pDiplayDrivers, - pustrDiplayDrivers->Buffer, - pustrDiplayDrivers->Length); - - /* Copy description */ - pGraphicsDevice->pwszDescription = pwsz + pustrDiplayDrivers->Length / sizeof(WCHAR); - RtlCopyMemory(pGraphicsDevice->pwszDescription, - pustrDescription->Buffer, - pustrDescription->Length); - pGraphicsDevice->pwszDescription[pustrDescription->Length/sizeof(WCHAR)] = 0; - - /* Initialize the pdevmodeInfo list and default index */ - pGraphicsDevice->pdevmodeInfo = NULL; - pGraphicsDevice->iDefaultMode = 0; - pGraphicsDevice->iCurrentMode = 0; - - // FIXME: initialize state flags - pGraphicsDevice->StateFlags = 0; + ASSERT(pGraphicsDevice->pdevmodeInfo == NULL); + ASSERT(pGraphicsDevice->pDevModeList == NULL); + + pwsz = pGraphicsDevice->pDiplayDrivers; /* Loop through the driver names * This is a REG_MULTI_SZ string */ @@ -138,7 +61,7 @@ } /* Get the mode list from the driver */ - pdminfo = LDEVOBJ_pdmiGetModes(pldev, pDeviceObject); + pdminfo = LDEVOBJ_pdmiGetModes(pldev, pGraphicsDevice->DeviceObject); if (!pdminfo) { ERR("Could not get mode list for '%ls'\n", pwsz); @@ -170,8 +93,7 @@ if (!pGraphicsDevice->pdevmodeInfo || cModes == 0) { ERR("No devmodes\n"); - ExFreePoolWithTag(pGraphicsDevice, GDITAG_GDEVICE); - return NULL; + return FALSE; } /* Allocate an index buffer */ @@ -182,8 +104,7 @@ if (!pGraphicsDevice->pDevModeList) { ERR("No devmode list\n"); - ExFreePoolWithTag(pGraphicsDevice, GDITAG_GDEVICE); - return NULL; + return FALSE; } TRACE("Looking for mode %lux%lux%lu(%lu Hz)\n", @@ -232,7 +153,106 @@ pGraphicsDevice->pDevModeList[i].pdm = pdm; i++; } - } + } + return TRUE; +} + +PGRAPHICS_DEVICE +NTAPI +EngpRegisterGraphicsDevice( + _In_ PUNICODE_STRING pustrDeviceName, + _In_ PUNICODE_STRING pustrDiplayDrivers, + _In_ PUNICODE_STRING pustrDescription, + _In_ PDEVMODEW pdmDefault) +{ + PGRAPHICS_DEVICE pGraphicsDevice; + PDEVICE_OBJECT pDeviceObject; + PFILE_OBJECT pFileObject; + NTSTATUS Status; + PWSTR pwsz; + ULONG cj; + SIZE_T cjWritten; + BOOL bEnable = TRUE; + + TRACE("EngpRegisterGraphicsDevice(%wZ)\n", pustrDeviceName); + + /* Allocate a GRAPHICS_DEVICE structure */ + pGraphicsDevice = ExAllocatePoolWithTag(PagedPool, + sizeof(GRAPHICS_DEVICE), + GDITAG_GDEVICE); + if (!pGraphicsDevice) + { + ERR("ExAllocatePoolWithTag failed\n"); + return NULL; + } + + /* Try to open the driver */ + Status = IoGetDeviceObjectPointer(pustrDeviceName, + FILE_READ_DATA | FILE_WRITE_DATA, + &pFileObject, + &pDeviceObject); + if (!NT_SUCCESS(Status)) + { + ERR("Could not open driver %wZ, 0x%lx\n", pustrDeviceName, Status); + ExFreePoolWithTag(pGraphicsDevice, GDITAG_GDEVICE); + return NULL; + } + + /* Enable the device */ + EngFileWrite(pFileObject, &bEnable, sizeof(BOOL), &cjWritten); + + /* Copy the device and file object pointers */ + pGraphicsDevice->DeviceObject = pDeviceObject; + pGraphicsDevice->FileObject = pFileObject; + + /* Copy device name */ + RtlStringCbCopyNW(pGraphicsDevice->szNtDeviceName, + sizeof(pGraphicsDevice->szNtDeviceName), + pustrDeviceName->Buffer, + pustrDeviceName->Length); + + /* Create a win device name (FIXME: virtual devices!) */ + swprintf(pGraphicsDevice->szWinDeviceName, L"\\\\.\\DISPLAY%d", (int)giDevNum); + + /* Allocate a buffer for the strings */ + cj = pustrDiplayDrivers->Length + pustrDescription->Length + sizeof(WCHAR); + pwsz = ExAllocatePoolWithTag(PagedPool, cj, GDITAG_DRVSUP); + if (!pwsz) + { + ERR("Could not allocate string buffer\n"); + ASSERT(FALSE); // FIXME + ExFreePoolWithTag(pGraphicsDevice, GDITAG_GDEVICE); + return NULL; + } + + /* Copy display driver names */ + pGraphicsDevice->pDiplayDrivers = pwsz; + RtlCopyMemory(pGraphicsDevice->pDiplayDrivers, + pustrDiplayDrivers->Buffer, + pustrDiplayDrivers->Length); + + /* Copy description */ + pGraphicsDevice->pwszDescription = pwsz + pustrDiplayDrivers->Length / sizeof(WCHAR); + RtlCopyMemory(pGraphicsDevice->pwszDescription, + pustrDescription->Buffer, + pustrDescription->Length); + pGraphicsDevice->pwszDescription[pustrDescription->Length/sizeof(WCHAR)] = 0; + + /* Initialize the pdevmodeInfo list and default index */ + pGraphicsDevice->pdevmodeInfo = NULL; + pGraphicsDevice->iDefaultMode = 0; + pGraphicsDevice->iCurrentMode = 0; + + // FIXME: initialize state flags + pGraphicsDevice->StateFlags = 0; + + /* Create the mode list */ + pGraphicsDevice->pDevModeList = NULL; + if (!EngpPopulateDeviceModeList(pGraphicsDevice, pdmDefault)) + { + ExFreePoolWithTag(pGraphicsDevice, GDITAG_GDEVICE); + return NULL; + } /* Lock loader */ EngAcquireSemaphore(ghsemGraphicsDeviceList); @@ -250,11 +270,10 @@ /* Unlock loader */ EngReleaseSemaphore(ghsemGraphicsDeviceList); - TRACE("Prepared %lu modes for %ls\n", cModes, pGraphicsDevice->pwszDescription); + TRACE("Prepared %lu modes for %ls\n", pGraphicsDevice->cDevModes, pGraphicsDevice->pwszDescription); return pGraphicsDevice; } - PGRAPHICS_DEVICE NTAPI Modified: branches/ros-branch-0_4_3/reactos/win32ss/gdi/eng/device.h URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/win32s…
============================================================================== --- branches/ros-branch-0_4_3/reactos/win32ss/gdi/eng/device.h [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/win32ss/gdi/eng/device.h [iso-8859-1] Sat Oct 29 18:25:32 2016 @@ -2,6 +2,11 @@ #pragma once #define TAG_GDEV 'gdev' + +VOID +NTAPI +PDEVOBJ_vRefreshModeList( + PPDEVOBJ ppdev); extern PGRAPHICS_DEVICE gpPrimaryGraphicsDevice; extern PGRAPHICS_DEVICE gpVgaGraphicsDevice; @@ -29,6 +34,11 @@ _In_ PUNICODE_STRING pustrDescription, _In_ PDEVMODEW pdmDefault); +BOOLEAN +EngpPopulateDeviceModeList( + _Inout_ PGRAPHICS_DEVICE pGraphicsDevice, + _In_ PDEVMODEW pdmDefault); + INIT_FUNCTION NTSTATUS NTAPI Modified: branches/ros-branch-0_4_3/reactos/win32ss/gdi/eng/pdevobj.c URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/win32s…
============================================================================== --- branches/ros-branch-0_4_3/reactos/win32ss/gdi/eng/pdevobj.c [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/win32ss/gdi/eng/pdevobj.c [iso-8859-1] Sat Oct 29 18:25:32 2016 @@ -249,6 +249,45 @@ DPRINT("PDEVOBJ_pSurface() returning %p\n", ppdev->pSurface); return ppdev->pSurface; +} + +VOID +NTAPI +PDEVOBJ_vRefreshModeList( + PPDEVOBJ ppdev) +{ + PGRAPHICS_DEVICE pGraphicsDevice; + PDEVMODEINFO pdminfo, pdmiNext; + DEVMODEW dmDefault; + + /* Lock the PDEV */ + EngAcquireSemaphore(ppdev->hsemDevLock); + + pGraphicsDevice = ppdev->pGraphicsDevice; + + /* Remember our default mode */ + dmDefault = *pGraphicsDevice->pDevModeList[pGraphicsDevice->iDefaultMode].pdm; + + /* Clear out the modes */ + for (pdminfo = pGraphicsDevice->pdevmodeInfo; + pdminfo; + pdminfo = pdmiNext) + { + pdmiNext = pdminfo->pdmiNext; + ExFreePoolWithTag(pdminfo, GDITAG_DEVMODE); + } + pGraphicsDevice->pdevmodeInfo = NULL; + ExFreePoolWithTag(pGraphicsDevice->pDevModeList, GDITAG_GDEVICE); + pGraphicsDevice->pDevModeList = NULL; + + /* Now re-populate the list */ + if (!EngpPopulateDeviceModeList(pGraphicsDevice, &dmDefault)) + { + DPRINT1("FIXME: EngpPopulateDeviceModeList failed, we just destroyed a perfectly good mode list\n"); + } + + /* Unlock PDEV */ + EngReleaseSemaphore(ppdev->hsemDevLock); } PDEVMODEW Modified: branches/ros-branch-0_4_3/reactos/win32ss/user/ntuser/display.c URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/win32s…
============================================================================== --- branches/ros-branch-0_4_3/reactos/win32ss/user/ntuser/display.c [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/win32ss/user/ntuser/display.c [iso-8859-1] Sat Oct 29 18:25:32 2016 @@ -463,19 +463,27 @@ PGRAPHICS_DEVICE pGraphicsDevice; PDEVMODEENTRY pdmentry; ULONG i, iFoundMode; + PPDEVOBJ ppdev; TRACE("Enter UserEnumDisplaySettings('%wZ', %lu)\n", pustrDevice, iModeNum); /* Ask GDI for the GRAPHICS_DEVICE */ pGraphicsDevice = EngpFindGraphicsDevice(pustrDevice, 0, 0); - - if (!pGraphicsDevice) + ppdev = EngpGetPDEV(pustrDevice); + + if (!pGraphicsDevice || !ppdev) { /* No device found */ ERR("No device found!\n"); return STATUS_INVALID_PARAMETER_1; } + + /* let's politely ask the driver for an updated mode list, + just in case there's something new in there (vbox) */ + + PDEVOBJ_vRefreshModeList(ppdev); + PDEVOBJ_vRelease(ppdev); iFoundMode = 0; for (i = 0; i < pGraphicsDevice->cDevModes; i++)
8 years, 1 month
1
0
0
0
[phater] 73068: [MSAFD][WS2_32] Better WSASocket parameters check CORE-12104
by phater@svn.reactos.org
Author: phater Date: Sat Oct 29 18:22:22 2016 New Revision: 73068 URL:
http://svn.reactos.org/svn/reactos?rev=73068&view=rev
Log: [MSAFD][WS2_32] Better WSASocket parameters check CORE-12104 Modified: trunk/reactos/dll/win32/msafd/misc/dllmain.c trunk/reactos/dll/win32/ws2_32/src/dcatalog.c Modified: trunk/reactos/dll/win32/msafd/misc/dllmain.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msafd/misc/dllma…
============================================================================== --- trunk/reactos/dll/win32/msafd/misc/dllmain.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/msafd/misc/dllmain.c [iso-8859-1] Sat Oct 29 18:22:22 2016 @@ -95,13 +95,33 @@ Protocol = SharedData->Protocol; } - if (AddressFamily == AF_UNSPEC && SocketType == 0 && Protocol == 0) + if (lpProtocolInfo) + { + if (lpProtocolInfo->iAddressFamily && AddressFamily <= 0) + AddressFamily = lpProtocolInfo->iAddressFamily; + if (lpProtocolInfo->iSocketType && SocketType <= 0) + SocketType = lpProtocolInfo->iSocketType; + if (lpProtocolInfo->iProtocol && Protocol <= 0) + Protocol = lpProtocolInfo->iProtocol; + } + + /* FIXME: AF_NETDES should be AF_MAX */ + if (AddressFamily < AF_UNSPEC || AddressFamily > AF_NETDES) return WSAEINVAL; + if (SocketType < 0 && SocketType > SOCK_SEQPACKET) + return WSAEINVAL; + + if (Protocol < 0 && Protocol > IPPROTO_MAX) + return WSAEINVAL; + + /* when no protocol and socket type are specified the first entry + * from WSAEnumProtocols that has the flag PFL_MATCHES_PROTOCOL_ZERO + * is returned */ + if (SocketType == 0 && Protocol == 0 && lpProtocolInfo && (lpProtocolInfo->dwProviderFlags & PFL_MATCHES_PROTOCOL_ZERO) == 0) + return WSAEINVAL; + /* Set the defaults */ - if (AddressFamily == AF_UNSPEC) - AddressFamily = AF_INET; - if (SocketType == 0) { switch (Protocol) @@ -117,8 +137,7 @@ break; default: TRACE("Unknown Protocol (%d). We will try SOCK_STREAM.\n", Protocol); - SocketType = SOCK_STREAM; - break; + return WSAEINVAL; } } @@ -137,10 +156,12 @@ break; default: TRACE("Unknown SocketType (%d). We will try IPPROTO_TCP.\n", SocketType); - Protocol = IPPROTO_TCP; - break; - } - } + return WSAEINVAL; + } + } + + if (AddressFamily == AF_UNSPEC) + return WSAEINVAL; /* Get Helper Data and Transport */ Status = SockGetTdiName (&AddressFamily, Modified: trunk/reactos/dll/win32/ws2_32/src/dcatalog.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/ws2_32/src/dcata…
============================================================================== --- trunk/reactos/dll/win32/ws2_32/src/dcatalog.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/ws2_32/src/dcatalog.c [iso-8859-1] Sat Oct 29 18:22:22 2016 @@ -490,6 +490,20 @@ /* Assume failure */ *CatalogEntry = NULL; + /* Params can't be all wildcards */ + if (af == AF_UNSPEC && type == 0 && protocol == 0) + return WSAEINVAL; + + /* FIXME: AF_NETDES should be AF_MAX */ + if (af < AF_UNSPEC || af > AF_NETDES) + return WSAEINVAL; + + if (type < 0 && type > SOCK_SEQPACKET) + return WSAEINVAL; + + if (protocol < 0 && protocol > IPPROTO_MAX) + return WSAEINVAL; + /* Lock the catalog */ WsTcLock(); @@ -527,6 +541,13 @@ Entry->ProtocolInfo.iProtocolMaxOffset) >= protocol)) || (protocol == 0)) { + /* Check that if type and protocol are 0 provider entry has PFL_MATCHES_PROTOCOL_ZERO flag set */ + if (type == 0 && protocol == 0 && (Entry->ProtocolInfo.dwProviderFlags & PFL_MATCHES_PROTOCOL_ZERO) == 0) + { + ErrorCode = WSAEPROTONOSUPPORT; + continue; + } + /* Check if it doesn't already have a provider */ if (!Entry->Provider) { @@ -550,12 +571,14 @@ } else { - ErrorCode = WSAESOCKTNOSUPPORT; + if (ErrorCode != WSAEPROTONOSUPPORT) + ErrorCode = WSAESOCKTNOSUPPORT; } } else { - ErrorCode = WSAEAFNOSUPPORT; + if (ErrorCode != WSAEPROTONOSUPPORT && ErrorCode != WSAESOCKTNOSUPPORT) + ErrorCode = WSAEAFNOSUPPORT; } }
8 years, 1 month
1
0
0
0
[tfaber] 73067: [0.4.3] - Update start menu banner
by tfaber@svn.reactos.org
Author: tfaber Date: Sat Oct 29 18:11:47 2016 New Revision: 73067 URL:
http://svn.reactos.org/svn/reactos?rev=73067&view=rev
Log: [0.4.3] - Update start menu banner Added: branches/ros-branch-0_4_3/reactos/base/shell/explorer/res/bmp/158-rc1.bmp - copied, changed from r73066, branches/ros-branch-0_4_3/reactos/base/shell/explorer/res/bmp/158.bmp branches/ros-branch-0_4_3/reactos/base/shell/explorer/res/bmp/158-rc2.bmp - copied, changed from r73066, branches/ros-branch-0_4_3/reactos/base/shell/explorer/res/bmp/158.bmp branches/ros-branch-0_4_3/reactos/base/shell/explorer/res/bmp/158-rc3.bmp - copied, changed from r73066, branches/ros-branch-0_4_3/reactos/base/shell/explorer/res/bmp/158.bmp Modified: branches/ros-branch-0_4_3/reactos/base/shell/explorer/res/bmp/158.bmp Copied: branches/ros-branch-0_4_3/reactos/base/shell/explorer/res/bmp/158-rc1.bmp (from r73066, branches/ros-branch-0_4_3/reactos/base/shell/explorer/res/bmp/158.bmp) URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/s…
============================================================================== Binary files - no diff available. Copied: branches/ros-branch-0_4_3/reactos/base/shell/explorer/res/bmp/158-rc2.bmp (from r73066, branches/ros-branch-0_4_3/reactos/base/shell/explorer/res/bmp/158.bmp) URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/s…
============================================================================== Binary files - no diff available. Copied: branches/ros-branch-0_4_3/reactos/base/shell/explorer/res/bmp/158-rc3.bmp (from r73066, branches/ros-branch-0_4_3/reactos/base/shell/explorer/res/bmp/158.bmp) URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/s…
============================================================================== Binary files - no diff available. Modified: branches/ros-branch-0_4_3/reactos/base/shell/explorer/res/bmp/158.bmp URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/s…
============================================================================== Binary files - no diff available.
8 years, 1 month
1
0
0
0
[akhaldi] 73066: [0.4.3] Add a hack by Thomas to avoid MmGetPhysicalAddress failures during USB transfers. CORE-9224
by akhaldi@svn.reactos.org
Author: akhaldi Date: Sat Oct 29 18:07:53 2016 New Revision: 73066 URL:
http://svn.reactos.org/svn/reactos?rev=73066&view=rev
Log: [0.4.3] Add a hack by Thomas to avoid MmGetPhysicalAddress failures during USB transfers. CORE-9224 Modified: branches/ros-branch-0_4_3/reactos/drivers/usb/usbehci/usb_request.cpp branches/ros-branch-0_4_3/reactos/drivers/usb/usbohci/usb_request.cpp Modified: branches/ros-branch-0_4_3/reactos/drivers/usb/usbehci/usb_request.cpp URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/driver…
============================================================================== --- branches/ros-branch-0_4_3/reactos/drivers/usb/usbehci/usb_request.cpp [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/drivers/usb/usbehci/usb_request.cpp [iso-8859-1] Sat Oct 29 18:07:53 2016 @@ -601,6 +601,7 @@ // // get address // + *(volatile char *)TransferBuffer; // HACK for CORE-9224 Address = MmGetPhysicalAddress(TransferBuffer); // Modified: branches/ros-branch-0_4_3/reactos/drivers/usb/usbohci/usb_request.cpp URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/driver…
============================================================================== --- branches/ros-branch-0_4_3/reactos/drivers/usb/usbohci/usb_request.cpp [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/drivers/usb/usbohci/usb_request.cpp [iso-8859-1] Sat Oct 29 18:07:53 2016 @@ -771,6 +771,7 @@ // // get physical page // + *(volatile char *)Buffer; // HACK for CORE-9224 Page = MmGetPhysicalAddress(Buffer).LowPart; // @@ -1087,6 +1088,7 @@ // // store physical address of buffer // + *(volatile char *)TransferBuffer; // HACK for CORE-9224 CurrentDescriptor->BufferPhysical = MmGetPhysicalAddress(TransferBuffer).LowPart; CurrentDescriptor->LastPhysicalByteAddress = CurrentDescriptor->BufferPhysical + TransferBufferLength - 1; @@ -1503,6 +1505,7 @@ // // store physical address of buffer // + *(volatile char *)MmGetMdlVirtualAddress(m_TransferBufferMDL); // HACK for CORE-9224 DataDescriptor->BufferPhysical = MmGetPhysicalAddress(MmGetMdlVirtualAddress(m_TransferBufferMDL)).LowPart; DataDescriptor->LastPhysicalByteAddress = DataDescriptor->BufferPhysical + m_TransferBufferLength - 1;
8 years, 1 month
1
0
0
0
[akhaldi] 73065: [0.4.3] * Disable COMMAND.COM debugging messages. CORE-10710
by akhaldi@svn.reactos.org
Author: akhaldi Date: Sat Oct 29 18:00:23 2016 New Revision: 73065 URL:
http://svn.reactos.org/svn/reactos?rev=73065&view=rev
Log: [0.4.3] * Disable
COMMAND.COM
debugging messages. CORE-10710 Modified: branches/ros-branch-0_4_3/reactos/subsystems/mvdm/dos/command.S Modified: branches/ros-branch-0_4_3/reactos/subsystems/mvdm/dos/command.S URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/subsys…
============================================================================== --- branches/ros-branch-0_4_3/reactos/subsystems/mvdm/dos/command.S [iso-8859-1] (original) +++ branches/ros-branch-0_4_3/reactos/subsystems/mvdm/dos/command.S [iso-8859-1] Sat Oct 29 18:00:23 2016 @@ -17,7 +17,7 @@ #include "asmxtras.inc" #include <isvbop.inc> -// #define NDEBUG +#define NDEBUG /* DEFINES ********************************************************************/
8 years, 1 month
1
0
0
0
[akhaldi] 73064: [0.4.3] * Apply the Wordpad related hack from CORE-5823 by Jared Smudde.
by akhaldi@svn.reactos.org
Author: akhaldi Date: Sat Oct 29 17:59:09 2016 New Revision: 73064 URL:
http://svn.reactos.org/svn/reactos?rev=73064&view=rev
Log: [0.4.3] * Apply the Wordpad related hack from CORE-5823 by Jared Smudde. Modified: branches/ros-branch-0_4_3/reactos/base/applications/wordpad/res/formatbar.bmp branches/ros-branch-0_4_3/reactos/base/applications/wordpad/res/toolbar.bmp Modified: branches/ros-branch-0_4_3/reactos/base/applications/wordpad/res/formatbar.bmp URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/a…
============================================================================== Binary files - no diff available. Modified: branches/ros-branch-0_4_3/reactos/base/applications/wordpad/res/toolbar.bmp URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_4_3/reactos/base/a…
============================================================================== Binary files - no diff available.
8 years, 1 month
1
0
0
0
← Newer
1
2
3
4
5
6
...
23
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
Results per page:
10
25
50
100
200