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
June 2008
----- 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
23 participants
435 discussions
Start a n
N
ew thread
[cfinck] 34116: - Set "lake.bmp" as the default wallpaper - Add a shortcut to "Download !" to the Desktop - Change the version number for the Explorer start menu bitmap
by cfinck@svn.reactos.org
Author: cfinck Date: Thu Jun 26 17:11:24 2008 New Revision: 34116 URL:
http://svn.reactos.org/svn/reactos?rev=34116&view=rev
Log: - Set "lake.bmp" as the default wallpaper - Add a shortcut to "Download !" to the Desktop - Change the version number for the Explorer start menu bitmap Modified: branches/ros-branch-0_3_5/reactos/base/shell/explorer/res/logov.bmp branches/ros-branch-0_3_5/reactos/boot/bootdata/hivedef.inf branches/ros-branch-0_3_5/reactos/dll/win32/syssetup/install.c Modified: branches/ros-branch-0_3_5/reactos/base/shell/explorer/res/logov.bmp URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_3_5/reactos/base/s…
============================================================================== Binary files - no diff available. Modified: branches/ros-branch-0_3_5/reactos/boot/bootdata/hivedef.inf URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_3_5/reactos/boot/b…
============================================================================== --- branches/ros-branch-0_3_5/reactos/boot/bootdata/hivedef.inf [iso-8859-1] (original) +++ branches/ros-branch-0_3_5/reactos/boot/bootdata/hivedef.inf [iso-8859-1] Thu Jun 26 17:11:24 2008 @@ -20,7 +20,7 @@ HKCU,"Control Panel\Desktop","HungAppTimeout",0x00000002,"5000" HKCU,"Control Panel\Desktop","SCRNSAVE.EXE",0x00000000,"" HKCU,"Control Panel\Desktop","WaitToKillAppTimeout",0x00000002,"20000" -HKCU,"Control Panel\Desktop","Wallpaper",0x00000000,"" +HKCU,"Control Panel\Desktop","Wallpaper",0x00000000,"%SystemRoot%\lake.bmp" HKCU,"Control Panel\International",,0x00000012 HKCU,"Control Panel\International","Locale",0x00000000,"0409" HKCU,"Control Panel\International\Geo","Nation",0x00000000,"1" Modified: branches/ros-branch-0_3_5/reactos/dll/win32/syssetup/install.c URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_3_5/reactos/dll/wi…
============================================================================== --- branches/ros-branch-0_3_5/reactos/dll/win32/syssetup/install.c [iso-8859-1] (original) +++ branches/ros-branch-0_3_5/reactos/dll/win32/syssetup/install.c [iso-8859-1] Thu Jun 26 17:11:24 2008 @@ -756,6 +756,7 @@ /* Create desktop shortcuts */ CreateShortcut(CSIDL_DESKTOP, NULL, IDS_SHORT_CMD, _T("%SystemRoot%\\system32\\cmd.exe"), IDS_CMT_CMD, TRUE); + CreateShortcut(CSIDL_DESKTOP, NULL, IDS_SHORT_DOWNLOADER, _T("%SystemRoot%\\system32\\downloader.exe"), IDS_CMT_DOWNLOADER, TRUE); /* Create program startmenu shortcuts */ CreateShortcut(CSIDL_PROGRAMS, NULL, IDS_SHORT_EXPLORER, _T("%SystemRoot%\\explorer.exe"), IDS_CMT_EXPLORER, TRUE);
16 years, 6 months
1
0
0
0
[cfinck] 34115: Hack: Copy the toolbar image on our own instead of using CopyImage to solve the messed up toolbar graphics. See r31924 for more details
by cfinck@svn.reactos.org
Author: cfinck Date: Thu Jun 26 17:03:33 2008 New Revision: 34115 URL:
http://svn.reactos.org/svn/reactos?rev=34115&view=rev
Log: Hack: Copy the toolbar image on our own instead of using CopyImage to solve the messed up toolbar graphics. See r31924 for more details Modified: branches/ros-branch-0_3_5/reactos/dll/win32/comctl32/toolbar.c Modified: branches/ros-branch-0_3_5/reactos/dll/win32/comctl32/toolbar.c URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_3_5/reactos/dll/wi…
============================================================================== --- branches/ros-branch-0_3_5/reactos/dll/win32/comctl32/toolbar.c [iso-8859-1] (original) +++ branches/ros-branch-0_3_5/reactos/dll/win32/comctl32/toolbar.c [iso-8859-1] Thu Jun 26 17:03:33 2008 @@ -2666,7 +2666,33 @@ TRACE("adding hInst=%p nID=%d nButtons=%d\n", bitmap->hInst, bitmap->nID, bitmap->nButtons); /* Add bitmaps to the default image list */ if (bitmap->hInst == NULL) /* a handle was passed */ - hbmLoad = (HBITMAP)CopyImage(ULongToHandle(bitmap->nID), IMAGE_BITMAP, 0, 0, 0); + { + BITMAP bmp; + HBITMAP hOldBitmapBitmap, hOldBitmapLoad; + HDC hdcImage, hdcBitmap; + + /* copy the bitmap before adding it so that the user's bitmap + * doesn't get modified. + */ + GetObjectW ((HBITMAP)bitmap->nID, sizeof(BITMAP), (LPVOID)&bmp); + + hdcImage = CreateCompatibleDC(0); + hdcBitmap = CreateCompatibleDC(0); + + /* create new bitmap */ + hbmLoad = CreateBitmap (bmp.bmWidth, bmp.bmHeight, bmp.bmPlanes, bmp.bmBitsPixel, NULL); + hOldBitmapBitmap = SelectObject(hdcBitmap, (HBITMAP)bitmap->nID); + hOldBitmapLoad = SelectObject(hdcImage, hbmLoad); + + /* Copy the user's image */ + BitBlt (hdcImage, 0, 0, bmp.bmWidth, bmp.bmHeight, + hdcBitmap, 0, 0, SRCCOPY); + + SelectObject (hdcImage, hOldBitmapLoad); + SelectObject (hdcBitmap, hOldBitmapBitmap); + DeleteDC (hdcImage); + DeleteDC (hdcBitmap); + } else hbmLoad = CreateMappedBitmap(bitmap->hInst, bitmap->nID, 0, NULL, 0);
16 years, 6 months
1
0
0
0
[cfinck] 34114: Import Ged's mstsc hack from the 0.3.4 branch to solve the HitTest problem. See r31922 for more details
by cfinck@svn.reactos.org
Author: cfinck Date: Thu Jun 26 17:01:18 2008 New Revision: 34114 URL:
http://svn.reactos.org/svn/reactos?rev=34114&view=rev
Log: Import Ged's mstsc hack from the 0.3.4 branch to solve the HitTest problem. See r31922 for more details Modified: branches/ros-branch-0_3_5/reactos/base/applications/mstsc/connectdialog.c Modified: branches/ros-branch-0_3_5/reactos/base/applications/mstsc/connectdialog.c URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_3_5/reactos/base/a…
============================================================================== --- branches/ros-branch-0_3_5/reactos/base/applications/mstsc/connectdialog.c [iso-8859-1] (original) +++ branches/ros-branch-0_3_5/reactos/base/applications/mstsc/connectdialog.c [iso-8859-1] Thu Jun 26 17:01:18 2008 @@ -197,19 +197,12 @@ static VOID -GeneralOnInit(HWND hwnd, - PINFO pInfo) -{ - SetWindowLongPtrW(hwnd, - GWLP_USERDATA, - (LONG_PTR)pInfo); - - pInfo->hGeneralPage = hwnd; - +GeneralOnInit(PINFO pInfo) +{ SetWindowPos(pInfo->hGeneralPage, NULL, - 2, - 22, + 13, + 110, 0, 0, SWP_NOACTIVATE | SWP_NOOWNERZORDER | SWP_NOSIZE | SWP_NOZORDER); @@ -255,13 +248,14 @@ WPARAM wParam, LPARAM lParam) { - PINFO pInfo = (PINFO)GetWindowLongPtrW(hDlg, + PINFO pInfo = (PINFO)GetWindowLongPtrW(GetParent(hDlg), GWLP_USERDATA); switch (message) { case WM_INITDIALOG: - GeneralOnInit(hDlg, (PINFO)lParam); + pInfo->hGeneralPage = hDlg; + GeneralOnInit(pInfo); return TRUE; case WM_COMMAND: @@ -745,23 +739,16 @@ static VOID -DisplayOnInit(HWND hwnd, - PINFO pInfo) +DisplayOnInit(PINFO pInfo) { DISPLAY_DEVICEW displayDevice; DWORD iDevNum = 0; BOOL GotDev = FALSE; - SetWindowLongPtrW(hwnd, - GWLP_USERDATA, - (LONG_PTR)pInfo); - - pInfo->hDisplayPage = hwnd; - SetWindowPos(pInfo->hDisplayPage, NULL, - 2, - 22, + 13, + 110, 0, 0, SWP_NOACTIVATE | SWP_NOOWNERZORDER | SWP_NOSIZE | SWP_NOZORDER); @@ -835,13 +822,14 @@ WPARAM wParam, LPARAM lParam) { - PINFO pInfo = (PINFO)GetWindowLongPtrW(hDlg, + PINFO pInfo = (PINFO)GetWindowLongPtrW(GetParent(hDlg), GWLP_USERDATA); switch (message) { case WM_INITDIALOG: - DisplayOnInit(hDlg, (PINFO)lParam); + pInfo->hDisplayPage = hDlg; + DisplayOnInit(pInfo); return TRUE; case WM_DRAWITEM: @@ -983,11 +971,10 @@ pInfo->hTab = GetDlgItem(hwnd, IDC_TAB); if (pInfo->hTab) { - if (CreateDialogParamW(hInst, - MAKEINTRESOURCEW(IDD_GENERAL), - pInfo->hTab, - (DLGPROC)GeneralDlgProc, - (LPARAM)pInfo)) + if (CreateDialogW(hInst, + MAKEINTRESOURCEW(IDD_GENERAL), + hwnd, + (DLGPROC)GeneralDlgProc)) { WCHAR str[256]; ZeroMemory(&item, sizeof(TCITEM)); @@ -998,11 +985,10 @@ (void)TabCtrl_InsertItem(pInfo->hTab, 0, &item); } - if (CreateDialogParamW(hInst, - MAKEINTRESOURCEW(IDD_DISPLAY), - pInfo->hTab, - (DLGPROC)DisplayDlgProc, - (LPARAM)pInfo)) + if (CreateDialogW(hInst, + MAKEINTRESOURCEW(IDD_DISPLAY), + hwnd, + (DLGPROC)DisplayDlgProc)) { WCHAR str[256]; ZeroMemory(&item, sizeof(TCITEM));
16 years, 6 months
1
0
0
0
[cfinck] 34113: Change the version to 0.3.5
by cfinck@svn.reactos.org
Author: cfinck Date: Thu Jun 26 16:58:36 2008 New Revision: 34113 URL:
http://svn.reactos.org/svn/reactos?rev=34113&view=rev
Log: Change the version to 0.3.5 Modified: branches/ros-branch-0_3_5/reactos/include/reactos/version.h Modified: branches/ros-branch-0_3_5/reactos/include/reactos/version.h URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_3_5/reactos/includ…
============================================================================== --- branches/ros-branch-0_3_5/reactos/include/reactos/version.h [iso-8859-1] (original) +++ branches/ros-branch-0_3_5/reactos/include/reactos/version.h [iso-8859-1] Thu Jun 26 16:58:36 2008 @@ -18,13 +18,13 @@ #define __VERSION_H #define KERNEL_VERSION_MAJOR 0 -#define KERNEL_VERSION_MINOR 4 -#define KERNEL_VERSION_PATCH_LEVEL 0 +#define KERNEL_VERSION_MINOR 3 +#define KERNEL_VERSION_PATCH_LEVEL 5 #define COPYRIGHT_YEAR "2008" /* KERNEL_VERSION_BUILD_TYPE is L"SVN", L"RC1", L"RC2" or L"" (for the release) */ -#define KERNEL_VERSION_BUILD_TYPE L"SVN" +#define KERNEL_VERSION_BUILD_TYPE L"" #endif
16 years, 6 months
1
0
0
0
[jmorlan] 34112: Make EnumDeviceDrivers and EnumProcessModules return the total size, even if the buffer is smaller. (from bug 3319)
by jmorlan@svn.reactos.org
Author: jmorlan Date: Thu Jun 26 14:52:05 2008 New Revision: 34112 URL:
http://svn.reactos.org/svn/reactos?rev=34112&view=rev
Log: Make EnumDeviceDrivers and EnumProcessModules return the total size, even if the buffer is smaller. (from bug 3319) Modified: trunk/reactos/dll/win32/psapi/psapi.c Modified: trunk/reactos/dll/win32/psapi/psapi.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/psapi/psapi.c?re…
============================================================================== --- trunk/reactos/dll/win32/psapi/psapi.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/psapi/psapi.c [iso-8859-1] Thu Jun 26 14:52:05 2008 @@ -39,6 +39,7 @@ { LPVOID *lpImageBase; DWORD nCount; + DWORD nTotal; } ENUM_DEVICE_DRIVERS_CONTEXT, *PENUM_DEVICE_DRIVERS_CONTEXT; NTSTATUS STDCALL @@ -47,19 +48,18 @@ { PENUM_DEVICE_DRIVERS_CONTEXT Context = (PENUM_DEVICE_DRIVERS_CONTEXT)CallbackContext; - /* no more buffer space */ - if(Context->nCount == 0) - { - return STATUS_INFO_LENGTH_MISMATCH; - } - - /* return current module */ - *Context->lpImageBase = CurrentModule->ImageBase; - - /* go to next array slot */ - Context->lpImageBase++; - Context->nCount--; - + /* check if more buffer space is available */ + if(Context->nCount != 0) + { + /* return current module */ + *Context->lpImageBase = CurrentModule->ImageBase; + + /* go to next array slot */ + Context->lpImageBase++; + Context->nCount--; + } + + Context->nTotal++; return STATUS_SUCCESS; } @@ -97,6 +97,7 @@ { HMODULE *lphModule; DWORD nCount; + DWORD nTotal; } ENUM_PROCESS_MODULES_CONTEXT, *PENUM_PROCESS_MODULES_CONTEXT; NTSTATUS STDCALL @@ -106,19 +107,18 @@ { PENUM_PROCESS_MODULES_CONTEXT Context = (PENUM_PROCESS_MODULES_CONTEXT)CallbackContext; - /* no more buffer space */ - if(Context->nCount == 0) - { - return STATUS_INFO_LENGTH_MISMATCH; - } - - /* return current process */ - *Context->lphModule = CurrentModule->DllBase; - - /* go to next array slot */ - Context->lphModule++; - Context->nCount--; - + /* check if more buffer space is available */ + if(Context->nCount != 0) + { + /* return current process */ + *Context->lphModule = CurrentModule->DllBase; + + /* go to next array slot */ + Context->lphModule++; + Context->nCount--; + } + + Context->nTotal++; return STATUS_SUCCESS; } @@ -678,23 +678,18 @@ ENUM_DEVICE_DRIVERS_CONTEXT Context; NTSTATUS Status; - if(cb == 0 || lpImageBase == NULL) - { - *lpcbNeeded = 0; - return TRUE; - } - cb /= sizeof(PVOID); Context.lpImageBase = lpImageBase; Context.nCount = cb; + Context.nTotal = 0; Status = PsaEnumerateSystemModules(EnumDeviceDriversCallback, &Context); - /* return the count of bytes returned */ - *lpcbNeeded = (cb - Context.nCount) * sizeof(PVOID); - - if(!NT_SUCCESS(Status) && (Status != STATUS_INFO_LENGTH_MISMATCH)) + /* return the count of bytes that would be needed for a complete enumeration */ + *lpcbNeeded = Context.nTotal * sizeof(PVOID); + + if(!NT_SUCCESS(Status)) { SetLastErrorByStatus(Status); return FALSE; @@ -757,21 +752,16 @@ cb /= sizeof(HMODULE); - if(cb == 0 || lphModule == NULL) - { - *lpcbNeeded = 0; - return TRUE; - } - Context.lphModule = lphModule; Context.nCount = cb; + Context.nTotal = 0; /* enumerate the process modules */ Status = PsaEnumerateProcessModules(hProcess, EnumProcessModulesCallback, &Context); - *lpcbNeeded = (cb - Context.nCount) * sizeof(DWORD); - - if(!NT_SUCCESS(Status) && (Status != STATUS_INFO_LENGTH_MISMATCH)) + *lpcbNeeded = Context.nTotal * sizeof(HMODULE); + + if(!NT_SUCCESS(Status)) { SetLastErrorByStatus(Status); return FALSE;
16 years, 6 months
1
0
0
0
[fireball] 34111: Yuri Sidorov <jura@cp-lab.com> - Properly set dwFirstChance member EXCEPTION_DEBUG_INFO structure returned by WaitForDebugEvent function. - Properly handle dwContinueStatus parameter of ContinueDebugEvent function. See issue #3393 for more details.
by fireball@svn.reactos.org
Author: fireball Date: Thu Jun 26 14:16:59 2008 New Revision: 34111 URL:
http://svn.reactos.org/svn/reactos?rev=34111&view=rev
Log: Yuri Sidorov <jura(a)cp-lab.com> - Properly set dwFirstChance member EXCEPTION_DEBUG_INFO structure returned by WaitForDebugEvent function. - Properly handle dwContinueStatus parameter of ContinueDebugEvent function. See issue #3393 for more details. Modified: trunk/reactos/ntoskrnl/dbgk/dbgkobj.c Modified: trunk/reactos/ntoskrnl/dbgk/dbgkobj.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/dbgk/dbgkobj.c?re…
============================================================================== --- trunk/reactos/ntoskrnl/dbgk/dbgkobj.c [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/dbgk/dbgkobj.c [iso-8859-1] Thu Jun 26 14:16:59 2008 @@ -865,6 +865,9 @@ /* Copy the exception record */ WaitStateChange->StateInfo.Exception.ExceptionRecord = DebugEvent->ApiMsg.Exception.ExceptionRecord; + /* Copy FirstChance flag */ + WaitStateChange->StateInfo.Exception.FirstChance = + DebugEvent->ApiMsg.Exception.FirstChance; break; /* Process exited */ @@ -1598,7 +1601,7 @@ if (NeedsWake) { /* Set the continue status */ - DebugEvent->ApiMsg.ReturnedStatus = Status; + DebugEvent->ApiMsg.ReturnedStatus = ContinueStatus; DebugEvent->Status = STATUS_SUCCESS; /* Wake the target */
16 years, 6 months
1
0
0
0
[cfinck] 34110: [20:44] <Fireball> Colin_Finck - branch!!!
by cfinck@svn.reactos.org
Author: cfinck Date: Thu Jun 26 13:16:20 2008 New Revision: 34110 URL:
http://svn.reactos.org/svn/reactos?rev=34110&view=rev
Log: [20:44] <Fireball> Colin_Finck - branch!!! Added: branches/ros-branch-0_3_5/ - copied from r34109, trunk/
16 years, 6 months
1
0
0
0
[mkupfer] 34109: - fix for missing letter in "DISPLAYSETTINGSUPDATE" - initial version of i18n hives (translatable registry entries)
by mkupfer@svn.reactos.org
Author: mkupfer Date: Thu Jun 26 11:53:26 2008 New Revision: 34109 URL:
http://svn.reactos.org/svn/reactos?rev=34109&view=rev
Log: - fix for missing letter in "DISPLAYSETTINGSUPDATE" - initial version of i18n hives (translatable registry entries) Added: branches/matthias-i18n/boot/bootdata/de_DE.inf (with props) Modified: branches/matthias-i18n/base/setup/usetup/interface/usetup.c branches/matthias-i18n/base/setup/usetup/lang/bg-BG.h branches/matthias-i18n/base/setup/usetup/lang/cs-CZ.h branches/matthias-i18n/base/setup/usetup/lang/de-DE.h branches/matthias-i18n/base/setup/usetup/lang/el-GR.h branches/matthias-i18n/base/setup/usetup/lang/en-US.h branches/matthias-i18n/base/setup/usetup/lang/es-ES.h branches/matthias-i18n/base/setup/usetup/lang/fr-FR.h branches/matthias-i18n/base/setup/usetup/lang/it-IT.h branches/matthias-i18n/base/setup/usetup/lang/lt-LT.h branches/matthias-i18n/base/setup/usetup/lang/pl-PL.h branches/matthias-i18n/base/setup/usetup/lang/ru-RU.h branches/matthias-i18n/base/setup/usetup/lang/sk-SK.h branches/matthias-i18n/base/setup/usetup/lang/sv-SE.h branches/matthias-i18n/base/setup/usetup/lang/uk-UA.h branches/matthias-i18n/base/setup/usetup/mui.h branches/matthias-i18n/boot/bootdata/bootdata.rbuild branches/matthias-i18n/boot/bootdata/txtsetup.sif Modified: branches/matthias-i18n/base/setup/usetup/interface/usetup.c URL:
http://svn.reactos.org/svn/reactos/branches/matthias-i18n/base/setup/usetup…
============================================================================== --- branches/matthias-i18n/base/setup/usetup/interface/usetup.c [iso-8859-1] (original) +++ branches/matthias-i18n/base/setup/usetup/interface/usetup.c [iso-8859-1] Thu Jun 26 11:53:26 2008 @@ -3135,6 +3135,7 @@ PWSTR Action; PWSTR File; PWSTR Section; + PWSTR LangId; BOOLEAN Delete; NTSTATUS Status; @@ -3207,8 +3208,54 @@ } } while (SetupFindNextLine (&InfContext, &InfContext)); + /* Localize registry entries by applying of language updates */ + + if (!SetupFindFirstLineW(SetupInf, L"HiveLocaleInfs.Install", NULL, &InfContext)) + { + DPRINT1("SetupFindFirstLine() failed\n"); + MUIDisplayError(ERROR_FIND_REGISTRY, Ir, POPUP_WAIT_ENTER); + return QUIT_PAGE; + } + + do + { + INF_GetDataField (&InfContext, 0, &Action); + INF_GetDataField (&InfContext, 1, &File); + INF_GetDataField (&InfContext, 2, &Section); + INF_GetDataField (&InfContext, 3, &LangId); + + DPRINT("Action: %S File: %S Section %S LangId %S\n", Action, File, Section, LangId); + + if (!_wcsicmp (Action, L"AddReg")) + { + Delete = FALSE; + } + else if (!_wcsicmp (Action, L"DelReg")) + { + Delete = TRUE; + } + else + { + continue; + } + + if (_wcsicmp(SelectedLanguageId, LangId)) /* language id doesn't match or exist */ + continue; + + CONSOLE_SetStatusText(MUIGetString(STRING_IMPORTFILE), File); + + if (!ImportRegistryFile(File, Section, Delete)) + { + DPRINT("Importing %S failed\n", File); + + MUIDisplayError(ERROR_IMPORT_HIVE, Ir, POPUP_WAIT_ENTER); + return QUIT_PAGE; + } + } while (SetupFindNextLine (&InfContext, &InfContext)); + + /* Update display registry settings */ - CONSOLE_SetStatusText(MUIGetString(STRING_DISPLAYETTINGSUPDATE)); + CONSOLE_SetStatusText(MUIGetString(STRING_DISPLAYSETTINGSUPDATE)); if (!ProcessDisplayRegistry(SetupInf, DisplayList)) { MUIDisplayError(ERROR_UPDATE_DISPLAY_SETTINGS, Ir, POPUP_WAIT_ENTER); Modified: branches/matthias-i18n/base/setup/usetup/lang/bg-BG.h URL:
http://svn.reactos.org/svn/reactos/branches/matthias-i18n/base/setup/usetup…
============================================================================== --- branches/matthias-i18n/base/setup/usetup/lang/bg-BG.h [iso-8859-1] (original) +++ branches/matthias-i18n/base/setup/usetup/lang/bg-BG.h [iso-8859-1] Thu Jun 26 11:53:26 2008 @@ -1633,7 +1633,7 @@ " áê¢à¥¬¥ï¢ ¥ ॣ¨áâêà¨â¥ ஥¢¥..."}, {STRING_IMPORTFILE, " áï¥ %S..."}, - {STRING_DISPLAYETTINGSUPDATE, + {STRING_DISPLAYSETTINGSUPDATE, " áê¢à¥¬¥ï¢ ¥ ॣ¨áâ஢¨â¥ áâனª¨ ¥ªà ..."}, {STRING_LOCALESETTINGSUPDATE, " áê¢à¥¬¥ï¢ ¥ ¬¥áâ¨â¥ áâனª¨..."}, Modified: branches/matthias-i18n/base/setup/usetup/lang/cs-CZ.h URL:
http://svn.reactos.org/svn/reactos/branches/matthias-i18n/base/setup/usetup…
============================================================================== --- branches/matthias-i18n/base/setup/usetup/lang/cs-CZ.h [iso-8859-1] (original) +++ branches/matthias-i18n/base/setup/usetup/lang/cs-CZ.h [iso-8859-1] Thu Jun 26 11:53:26 2008 @@ -1630,7 +1630,7 @@ " Aktualizuji registr..."}, {STRING_IMPORTFILE, " Importuji %S..."}, - {STRING_DISPLAYETTINGSUPDATE, + {STRING_DISPLAYSETTINGSUPDATE, " Aktualizuji nastaven¡ zobrazen¡ registru..."}, //display registry settings {STRING_LOCALESETTINGSUPDATE, " Aktualizuji m¡stn¡ nastaven¡..."}, Modified: branches/matthias-i18n/base/setup/usetup/lang/de-DE.h URL:
http://svn.reactos.org/svn/reactos/branches/matthias-i18n/base/setup/usetup…
============================================================================== --- branches/matthias-i18n/base/setup/usetup/lang/de-DE.h [iso-8859-1] (original) +++ branches/matthias-i18n/base/setup/usetup/lang/de-DE.h [iso-8859-1] Thu Jun 26 11:53:26 2008 @@ -1624,7 +1624,7 @@ " Registry hives werden aktualisiert..."}, {STRING_IMPORTFILE, " Importiere %S..."}, - {STRING_DISPLAYETTINGSUPDATE, + {STRING_DISPLAYSETTINGSUPDATE, " Bildschirm-Registryeinstellungen werden aktualisiert..."}, {STRING_LOCALESETTINGSUPDATE, " Lokalisierungseinstellungen werden aktualisiert..."}, Modified: branches/matthias-i18n/base/setup/usetup/lang/el-GR.h URL:
http://svn.reactos.org/svn/reactos/branches/matthias-i18n/base/setup/usetup…
============================================================================== --- branches/matthias-i18n/base/setup/usetup/lang/el-GR.h [iso-8859-1] (original) +++ branches/matthias-i18n/base/setup/usetup/lang/el-GR.h [iso-8859-1] Thu Jun 26 11:53:26 2008 @@ -1653,7 +1653,7 @@ " Updating registry hives..."}, {STRING_IMPORTFILE, " Importing %S..."}, - {STRING_DISPLAYETTINGSUPDATE, + {STRING_DISPLAYSETTINGSUPDATE, " Updating display registry settings..."}, {STRING_LOCALESETTINGSUPDATE, " Updating locale settings..."}, Modified: branches/matthias-i18n/base/setup/usetup/lang/en-US.h URL:
http://svn.reactos.org/svn/reactos/branches/matthias-i18n/base/setup/usetup…
============================================================================== --- branches/matthias-i18n/base/setup/usetup/lang/en-US.h [iso-8859-1] (original) +++ branches/matthias-i18n/base/setup/usetup/lang/en-US.h [iso-8859-1] Thu Jun 26 11:53:26 2008 @@ -1623,7 +1623,7 @@ " Updating registry hives..."}, {STRING_IMPORTFILE, " Importing %S..."}, - {STRING_DISPLAYETTINGSUPDATE, + {STRING_DISPLAYSETTINGSUPDATE, " Updating display registry settings..."}, {STRING_LOCALESETTINGSUPDATE, " Updating locale settings..."}, Modified: branches/matthias-i18n/base/setup/usetup/lang/es-ES.h URL:
http://svn.reactos.org/svn/reactos/branches/matthias-i18n/base/setup/usetup…
============================================================================== --- branches/matthias-i18n/base/setup/usetup/lang/es-ES.h [iso-8859-1] (original) +++ branches/matthias-i18n/base/setup/usetup/lang/es-ES.h [iso-8859-1] Thu Jun 26 11:53:26 2008 @@ -1623,7 +1623,7 @@ " Actualizando el rbol del registro..."}, {STRING_IMPORTFILE, " Importando %S..."}, - {STRING_DISPLAYETTINGSUPDATE, + {STRING_DISPLAYSETTINGSUPDATE, " Actualizando configuraci¢n del tipo de pantalla..."}, {STRING_LOCALESETTINGSUPDATE, " Actualizando configuraci¢n regional..."}, Modified: branches/matthias-i18n/base/setup/usetup/lang/fr-FR.h URL:
http://svn.reactos.org/svn/reactos/branches/matthias-i18n/base/setup/usetup…
============================================================================== --- branches/matthias-i18n/base/setup/usetup/lang/fr-FR.h [iso-8859-1] (original) +++ branches/matthias-i18n/base/setup/usetup/lang/fr-FR.h [iso-8859-1] Thu Jun 26 11:53:26 2008 @@ -1636,7 +1636,7 @@ " Mise jour de la base de registre..."}, {STRING_IMPORTFILE, " Importe %S..."}, - {STRING_DISPLAYETTINGSUPDATE, + {STRING_DISPLAYSETTINGSUPDATE, " Mise jour des paramtres du registre pour l'cran..."}, {STRING_LOCALESETTINGSUPDATE, " Mise jour des paramtres rgionaux..."}, Modified: branches/matthias-i18n/base/setup/usetup/lang/it-IT.h URL:
http://svn.reactos.org/svn/reactos/branches/matthias-i18n/base/setup/usetup…
============================================================================== --- branches/matthias-i18n/base/setup/usetup/lang/it-IT.h [iso-8859-1] (original) +++ branches/matthias-i18n/base/setup/usetup/lang/it-IT.h [iso-8859-1] Thu Jun 26 11:53:26 2008 @@ -1624,7 +1624,7 @@ " Aggiornamento degli hives del registro..."}, {STRING_IMPORTFILE, " Importazione di %S..."}, - {STRING_DISPLAYETTINGSUPDATE, + {STRING_DISPLAYSETTINGSUPDATE, " Aggiornamento delle impostazioni dello schermo nel registro..."}, {STRING_LOCALESETTINGSUPDATE, " Aggiornamento delle impostazioni di regionalizzazione..."}, Modified: branches/matthias-i18n/base/setup/usetup/lang/lt-LT.h URL:
http://svn.reactos.org/svn/reactos/branches/matthias-i18n/base/setup/usetup…
============================================================================== --- branches/matthias-i18n/base/setup/usetup/lang/lt-LT.h [iso-8859-1] (original) +++ branches/matthias-i18n/base/setup/usetup/lang/lt-LT.h [iso-8859-1] Thu Jun 26 11:53:26 2008 @@ -1633,7 +1633,7 @@ " Updating registry hives..."}, {STRING_IMPORTFILE, " Importing %S..."}, - {STRING_DISPLAYETTINGSUPDATE, + {STRING_DISPLAYSETTINGSUPDATE, " Updating display registry settings..."}, {STRING_LOCALESETTINGSUPDATE, " Updating locale settings..."}, Modified: branches/matthias-i18n/base/setup/usetup/lang/pl-PL.h URL:
http://svn.reactos.org/svn/reactos/branches/matthias-i18n/base/setup/usetup…
============================================================================== --- branches/matthias-i18n/base/setup/usetup/lang/pl-PL.h [iso-8859-1] (original) +++ branches/matthias-i18n/base/setup/usetup/lang/pl-PL.h [iso-8859-1] Thu Jun 26 11:53:26 2008 @@ -1632,7 +1632,7 @@ " Uaktualnianie..."}, {STRING_IMPORTFILE, " Importowanie %S..."}, - {STRING_DISPLAYETTINGSUPDATE, + {STRING_DISPLAYSETTINGSUPDATE, " Zmiana ustawieä ekranu w rejestrze..."}, {STRING_LOCALESETTINGSUPDATE, " Zmiana wersji j©zykowej..."}, Modified: branches/matthias-i18n/base/setup/usetup/lang/ru-RU.h URL:
http://svn.reactos.org/svn/reactos/branches/matthias-i18n/base/setup/usetup…
============================================================================== --- branches/matthias-i18n/base/setup/usetup/lang/ru-RU.h [iso-8859-1] (original) +++ branches/matthias-i18n/base/setup/usetup/lang/ru-RU.h [iso-8859-1] Thu Jun 26 11:53:26 2008 @@ -1624,7 +1624,7 @@ " ¡®¢«¥¨¥ ªãá⮢ ॥áâà ..."}, {STRING_IMPORTFILE, " ¬¯®àâ¨à®¢ ¨¥ %S..."}, - {STRING_DISPLAYETTINGSUPDATE, + {STRING_DISPLAYSETTINGSUPDATE, " ¡®¢«¥¨¥ ¯ à ¬¥â஢ íªà ¢ ॥áâà¥..."}, {STRING_LOCALESETTINGSUPDATE, " ¡®¢«¥¨¥ ¯ à ¬¥â஢ «®ª «¨..."}, Modified: branches/matthias-i18n/base/setup/usetup/lang/sk-SK.h URL:
http://svn.reactos.org/svn/reactos/branches/matthias-i18n/base/setup/usetup…
============================================================================== --- branches/matthias-i18n/base/setup/usetup/lang/sk-SK.h [iso-8859-1] (original) +++ branches/matthias-i18n/base/setup/usetup/lang/sk-SK.h [iso-8859-1] Thu Jun 26 11:53:26 2008 @@ -1631,7 +1631,7 @@ " Aktualizujem polo§ky registrov..."}, {STRING_IMPORTFILE, " Importujem %S..."}, - {STRING_DISPLAYETTINGSUPDATE, + {STRING_DISPLAYSETTINGSUPDATE, " Aktualizujem nastavenia obrazovky v registrov..."}, //display registry settings {STRING_LOCALESETTINGSUPDATE, " Aktualizujem miestne nastavenia..."}, Modified: branches/matthias-i18n/base/setup/usetup/lang/sv-SE.h URL:
http://svn.reactos.org/svn/reactos/branches/matthias-i18n/base/setup/usetup…
============================================================================== --- branches/matthias-i18n/base/setup/usetup/lang/sv-SE.h [iso-8859-1] (original) +++ branches/matthias-i18n/base/setup/usetup/lang/sv-SE.h [iso-8859-1] Thu Jun 26 11:53:26 2008 @@ -1623,7 +1623,7 @@ " Updating registry hives..."}, {STRING_IMPORTFILE, " Importing %S..."}, - {STRING_DISPLAYETTINGSUPDATE, + {STRING_DISPLAYSETTINGSUPDATE, " Updating display registry settings..."}, {STRING_LOCALESETTINGSUPDATE, " Updating locale settings..."}, Modified: branches/matthias-i18n/base/setup/usetup/lang/uk-UA.h URL:
http://svn.reactos.org/svn/reactos/branches/matthias-i18n/base/setup/usetup…
============================================================================== --- branches/matthias-i18n/base/setup/usetup/lang/uk-UA.h [iso-8859-1] (original) +++ branches/matthias-i18n/base/setup/usetup/lang/uk-UA.h [iso-8859-1] Thu Jun 26 11:53:26 2008 @@ -1624,7 +1624,7 @@ " Updating registry hives..."}, {STRING_IMPORTFILE, " Importing %S..."}, - {STRING_DISPLAYETTINGSUPDATE, + {STRING_DISPLAYSETTINGSUPDATE, " Updating display registry settings..."}, {STRING_LOCALESETTINGSUPDATE, " Updating locale settings..."}, Modified: branches/matthias-i18n/base/setup/usetup/mui.h URL:
http://svn.reactos.org/svn/reactos/branches/matthias-i18n/base/setup/usetup…
============================================================================== --- branches/matthias-i18n/base/setup/usetup/mui.h [iso-8859-1] (original) +++ branches/matthias-i18n/base/setup/usetup/mui.h [iso-8859-1] Thu Jun 26 11:53:26 2008 @@ -101,7 +101,7 @@ #define STRING_FREEMEM 19 #define STRING_REGHIVEUPDATE 20 #define STRING_IMPORTFILE 21 -#define STRING_DISPLAYETTINGSUPDATE 22 +#define STRING_DISPLAYSETTINGSUPDATE 22 #define STRING_LOCALESETTINGSUPDATE 23 #define STRING_KEYBOARDSETTINGSUPDATE 24 #define STRING_CODEPAGEINFOUPDATE 25 Modified: branches/matthias-i18n/boot/bootdata/bootdata.rbuild URL:
http://svn.reactos.org/svn/reactos/branches/matthias-i18n/boot/bootdata/boo…
============================================================================== --- branches/matthias-i18n/boot/bootdata/bootdata.rbuild [iso-8859-1] (original) +++ branches/matthias-i18n/boot/bootdata/bootdata.rbuild [iso-8859-1] Thu Jun 26 11:53:26 2008 @@ -8,6 +8,7 @@ <cdfile installbase="$(CDOUTPUT)">hivedef.inf</cdfile> <cdfile installbase="$(CDOUTPUT)">hivesft.inf</cdfile> <cdfile installbase="$(CDOUTPUT)">hivesys.inf</cdfile> + <cdfile installbase="$(CDOUTPUT)">de_DE.inf</cdfile> <cdfile installbase="$(CDOUTPUT)">txtsetup.sif</cdfile> <cdfile installbase="$(CDOUTPUT)">unattend.inf</cdfile> <directory name="bootcd"> Added: branches/matthias-i18n/boot/bootdata/de_DE.inf URL:
http://svn.reactos.org/svn/reactos/branches/matthias-i18n/boot/bootdata/de_…
============================================================================== --- branches/matthias-i18n/boot/bootdata/de_DE.inf (added) +++ branches/matthias-i18n/boot/bootdata/de_DE.inf [iso-8859-1] Thu Jun 26 11:53:26 2008 @@ -1,0 +1,88 @@ +[Version] +Signature="$ReactOS$ + +[AddReg] + +; Country Codes + +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\1","Name",0x00000000,"Vereinigte Staten von Amerika" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\106","Name",0x00000000,"Britische Jungferninseln" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\107","Name",0x00000000,"Kanada" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\109","Name",0x00000000,"Dominica" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\110","Name",0x00000000,"Dominikanische Republik" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\20","Name",0x00000000,"Ägypten" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\268","Name",0x00000000,"Swasiland" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\27","Name",0x00000000,"Südafrika" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\30","Name",0x00000000,"Griechenland" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\31","Name",0x00000000,"Niederlande" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\32","Name",0x00000000,"Belgien" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\33","Name",0x00000000,"Frankreich" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\34","Name",0x00000000,"Spanien" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\351","Name",0x00000000,"Portugal" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\352","Name",0x00000000,"Luxemburg" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\353","Name",0x00000000,"Irland" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\354","Name",0x00000000,"Island" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\355","Name",0x00000000,"Albanien" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\358","Name",0x00000000,"Finnland" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\359","Name",0x00000000,"Bulgarien" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\36","Name",0x00000000,"Ungarn" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\370","Name",0x00000000,"Litauen" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\371","Name",0x00000000,"Lettland" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\372","Name",0x00000000,"Estland" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\373","Name",0x00000000,"Moldawien" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\374","Name",0x00000000,"Armenien" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\380","Name",0x00000000,"Ukraine" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\381","Name",0x00000000,"Jugoslavien" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\385","Name",0x00000000,"Kroatien" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\386","Name",0x00000000,"Slowenien" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\387","Name",0x00000000,"Bosnien und Herzegowina" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\39","Name",0x00000000,"Italien" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\40","Name",0x00000000,"Romänien" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\41","Name",0x00000000,"Schweiz" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\420","Name",0x00000000,"Tschechische Republik" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\421","Name",0x00000000,"Slowakei" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\423","Name",0x00000000,"Liechtenstein" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\43","Name",0x00000000,"Österreich" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\44","Name",0x00000000,"Großbritannien" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\46","Name",0x00000000,"Schweden" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\47","Name",0x00000000,"Norwegen" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\48","Name",0x00000000,"Polen" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\49","Name",0x00000000,"Deutschland" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\52","Name",0x00000000,"Mexico" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\54","Name",0x00000000,"Argentinien" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\55","Name",0x00000000,"Brasilien" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\56","Name",0x00000000,"Chile" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\57","Name",0x00000000,"Kolombien" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\58","Name",0x00000000,"Venezuela" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\60","Name",0x00000000,"Malaysia" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\61","Name",0x00000000,"Australien" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\62","Name",0x00000000,"Indonesien" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\63","Name",0x00000000,"Philippinen" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\64","Name",0x00000000,"Neuseeland" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\7","Name",0x00000000,"Russland" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\705","Name",0x00000000,"Kasachstan" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\708","Name",0x00000000,"Tadschikistan" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\81","Name",0x00000000,"Japan" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\82","Name",0x00000000,"Republik Korea" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\850","Name",0x00000000,"Demokratische Volksrepublik Korea" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\86","Name",0x00000000,"China" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\886","Name",0x00000000,"Taiwan" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\90","Name",0x00000000,"Türkei" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\91","Name",0x00000000,"Indien" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\93","Name",0x00000000,"Afghanistan" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\960","Name",0x00000000,"Malediven" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\964","Name",0x00000000,"Irak" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\966","Name",0x00000000,"Saudi Arabien" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\971","Name",0x00000000,"Vereinigte Arabische Emirate" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\972","Name",0x00000000,"Israel" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\974","Name",0x00000000,"Katar" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\976","Name",0x00000000,"Mongolei" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\977","Name",0x00000000,"Nepal" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\98","Name",0x00000000,"Iran" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\993","Name",0x00000000,"Turkmenistan" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\994","Name",0x00000000,"Aserbaidschan" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\995","Name",0x00000000,"Georgien" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\996","Name",0x00000000,"Kirgistan" +HKLM,"SOFTWARE\Microsoft\Windows\CurrentVersion\Telephony\Country List\998","Name",0x00000000,"Usbekistan" + +; EOF Propchange: branches/matthias-i18n/boot/bootdata/de_DE.inf ------------------------------------------------------------------------------ svn:eol-style = native Modified: branches/matthias-i18n/boot/bootdata/txtsetup.sif URL:
http://svn.reactos.org/svn/reactos/branches/matthias-i18n/boot/bootdata/txt…
============================================================================== --- branches/matthias-i18n/boot/bootdata/txtsetup.sif [iso-8859-1] (original) +++ branches/matthias-i18n/boot/bootdata/txtsetup.sif [iso-8859-1] Thu Jun 26 11:53:26 2008 @@ -397,4 +397,7 @@ AddReg=hivesft.inf,AddReg AddReg=hivesys.inf,AddReg +[HiveLocaleInfs.Install] +AddReg=de_DE.inf,AddReg,00000407 + ; EOF
16 years, 6 months
1
0
0
0
[jmorlan] 34108: Fix infinite loop in PspDumpThreads
by jmorlan@svn.reactos.org
Author: jmorlan Date: Thu Jun 26 11:23:45 2008 New Revision: 34108 URL:
http://svn.reactos.org/svn/reactos?rev=34108&view=rev
Log: Fix infinite loop in PspDumpThreads Modified: trunk/reactos/ntoskrnl/ps/debug.c Modified: trunk/reactos/ntoskrnl/ps/debug.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/ps/debug.c?rev=34…
============================================================================== --- trunk/reactos/ntoskrnl/ps/debug.c [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/ps/debug.c [iso-8859-1] Thu Jun 26 11:23:45 2008 @@ -78,10 +78,10 @@ /* Print a new line if there's nothing */ if((i % 8) != 0) DbgPrint("\n"); } + + /* Move to the next Thread */ + CurrentThread = CurrentThread->Flink; } - - /* Move to the next Thread */ - CurrentThread = CurrentThread->Flink; } /* Move to the next Process */
16 years, 6 months
1
0
0
0
[mpiulachs] 34107: Clean up tools folder.
by mpiulachs@svn.reactos.org
Author: mpiulachs Date: Thu Jun 26 11:01:59 2008 New Revision: 34107 URL:
http://svn.reactos.org/svn/reactos?rev=34107&view=rev
Log: Clean up tools folder. Removed: trunk/reactos/tools/depends.c trunk/reactos/tools/make_ctests.c trunk/reactos/tools/mkflpimg.c trunk/reactos/tools/rcopy.c trunk/reactos/tools/rdel.c trunk/reactos/tools/regtests.c trunk/reactos/tools/rline.c trunk/reactos/tools/rmkdir.c trunk/reactos/tools/rrmdir.c trunk/reactos/tools/rtouch.c Removed: trunk/reactos/tools/depends.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/tools/depends.c?rev=34106&…
============================================================================== --- trunk/reactos/tools/depends.c [iso-8859-1] (original) +++ trunk/reactos/tools/depends.c (removed) @@ -1,109 +1,0 @@ -#include <stdio.h> -#include <stdlib.h> -#include <string.h> - -int main(int argc, char* argv[]) -{ - char buf[512]; - char buf2[512]; - char ch; - unsigned int i, j; - char* dot; - char* ext; - char* prefix; - FILE* out; - - if (argc != 3) - { - printf("Too few arguments\n"); - return(1); - } - - prefix = strdup(argv[1]); - - out = fopen(argv[2], "wb"); - if (out == NULL) - { - printf("Unable to open output file\n"); - return(1); - } - - i = 0; - while ((ch = fgetc(stdin)) == '#') - { - while ((ch = fgetc(stdin)) != '\n' && ch != EOF) - { - } - } - if (ch != EOF) - { - buf[i] = ch; - i++; - } - - while ((ch = fgetc(stdin)) != ':' && ch != EOF) - { - buf[i] = ch; - i++; - } - buf[i] = 0; - - if (i == 0) - { - return(0); - } - i = 0; - while ((ch = fgetc(stdin)) == ' ' && ch != EOF) - { - buf2[i] = ch; - i++; - } - if (i == 0) - { - return 0; - } - if (ch != EOF) - { - buf2[i] = ch; - i++; - } - j = i; - while ((ch = fgetc(stdin)) != ' ' && ch != EOF) - { - buf2[j] = ch; - j++; - } - buf2[j] = 0; - if (i == j) - { - return 0; - } - - ext = strrchr(buf2, '.'); - if (ext != NULL) - { - if (0 == strcmp(ext, ".h")) - { - ext = "h.gch"; - } - else - { - ext = NULL; - } - } - - dot = strrchr(buf, '.'); - if (dot != NULL) - { - *dot = 0; - } - fprintf(out, "%s/.%s.TAG %s/.%s.d %s/%s.%s:%s ", prefix, buf, prefix, buf, - prefix,buf,ext ? ext : "o" , buf2); - - while ((ch = fgetc(stdin)) != EOF) - { - fputc(ch, out); - } - - return(0); -} Removed: trunk/reactos/tools/make_ctests.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/tools/make_ctests.c?rev=34…
============================================================================== --- trunk/reactos/tools/make_ctests.c [iso-8859-1] (original) +++ trunk/reactos/tools/make_ctests.c (removed) @@ -1,132 +1,0 @@ -/* make_ctests.c - - * This program is a port of wine project's make_ctests script - -# Script to generate a C file containing a list of tests -# -# Copyright 2002 Alexandre Julliard -# Copyright 2002 Dimitrie O. Paun -# -# This library is free software; you can redistribute it and/or -# modify it under the terms of the GNU Lesser General Public -# License as published by the Free Software Foundation; either -# version 2.1 of the License, or (at your option) any later version. -# -# This library is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -# Lesser General Public License for more details. -# -# You should have received a copy of the GNU Lesser General Public -# License along with this library; if not, write to the Free Software -# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -# - -# ***** Keep in sync with tools/winapi/msvcmaker:_generate_testlist_c ***** -*/ - -#include <stdio.h> -#include <stdlib.h> - -const char* header = - "/* Automatically generated file; DO NOT EDIT!! */\n" - "\n" - "/* stdarg.h is needed for Winelib */\n" - "#include <stdarg.h>\n" - "#include <stdio.h>\n" - "#include <stdlib.h>\n" - "#include \"windef.h\"\n" - "#include \"winbase.h\"\n" - "\n"; - -const char* middle = - "\n" - "struct test\n" - "{\n" - " const char *name;\n" - " void (*func)(void);\n" - "};\n" - "\n" - "static const struct test winetest_testlist[] =\n" - "{\n"; - -const char* end = - " { 0, 0 }\n" - "};\n" - "\n" - "#define WINETEST_WANT_MAIN\n" - "#include \"wine/test.h\"\n" - "\n"; - -char* -basename ( const char* filename ) -{ - const char *p, *p2; - char *out; - size_t out_len; - - if ( filename == NULL ) - { - fprintf ( stderr, "basename() called with null filename\n" ); - return NULL; - } - p = strrchr ( filename, '/' ); - if ( !p ) - p = filename; - else - ++p; - - /* look for backslashes, too... */ - p2 = strrchr ( filename, '\\' ); - if ( p2 > p ) - p = p2 + 1; - - /* find extension... */ - p2 = strrchr ( filename, '.' ); - if ( !p2 ) - p2 = p + strlen(p); - - /* malloc a copy */ - out_len = p2-p; - out = malloc ( out_len+1 ); - if ( out == NULL ) - { - fprintf ( stderr, "malloc() failed\n" ); - return NULL; - } - memmove ( out, p, out_len ); - out[out_len] = '\0'; - return out; -} - -int -main ( int argc, const char** argv ) -{ - size_t i; - - printf ( "%s", header ); - - for ( i = 1; i < argc; i++ ) - { - char* test = basename(argv[i]); - if ( test == NULL ) - return 255; - printf ( "extern void func_%s(void);\n", test ); - free ( test ); - } - - printf ( "%s", middle ); - - for ( i = 1; i < argc; i++ ) - { - char* test = basename(argv[i]); - if ( test == NULL ) - return 255; - printf ( " { \"%s\", func_%s },\n", test, test ); - free ( test ); - } - - printf ( "%s", end ); - - return 0; -} Removed: trunk/reactos/tools/mkflpimg.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/tools/mkflpimg.c?rev=34106…
============================================================================== --- trunk/reactos/tools/mkflpimg.c [iso-8859-1] (original) +++ trunk/reactos/tools/mkflpimg.c (removed) @@ -1,347 +1,0 @@ -#include <ctype.h> -#include <stdio.h> -#include <stdlib.h> -#include <string.h> -#include <time.h> - -#define N_CYLINDERS 80 -#define ROOT_ENTRY_SIZE 32 - -#define SECTOR_SIZE 512 -#define SECTORS_PER_CLUSTER 1 -#define N_RESERVED 1 -#define N_FATS 2 -#define N_ROOT_ENTRIES 224 -#define SECTORS_PER_DISK (N_HEADS * N_CYLINDERS * SECTORS_PER_TRACK) -#define MEDIA_TYPE 0xf0 -#define SECTORS_PER_FAT 9 -#define SECTORS_PER_TRACK 18 -#define N_HEADS 2 -#define SIGNATURE 0x29 /* only MS? */ -#define END_SIGNATURE 0xaa55 - - -#define ATTR_READONLY 0x01 -#define ATTR_HIDDEN 0x02 -#define ATTR_SYSTEM 0x04 -#define ATTR_VOLUME 0x08 -#define ATTR_SUBDIR 0x10 -#define ATTR_ARCHIVE 0x20 -#define ATTR_RES1 0x40 -#define ATTR_RES2 0x80 - - -typedef unsigned char disk_sector_t[SECTOR_SIZE]; - -typedef struct boot_sector -{ - unsigned short jmp; - unsigned char nop; - char oem[8]; - unsigned short bytes_per_sector; - unsigned char sectors_per_cluster; - unsigned short reserved_sectors; - unsigned char n_fats; - unsigned short n_root_entries; - unsigned short n_sectors; - unsigned char media_type; - unsigned short sectors_per_fat; - unsigned short sectors_per_track; - unsigned short n_heads; - unsigned long hidden_sectors; - unsigned long huge_sectors; - unsigned char drive; - unsigned char reserved; - unsigned char signature; - unsigned long volume_id; - char volume_label[11]; - char file_system[8]; - unsigned char boot_code[SECTOR_SIZE - 62 - 2]; - unsigned short end_signature; -} __attribute__ ((packed)) boot_sector_t; - - -typedef struct root_entry -{ - char name[8]; - char extension[3]; - unsigned char attribute; - unsigned char reserved[10]; - unsigned short time; - unsigned short date; - unsigned short cluster; - unsigned long size; -} __attribute ((packed)) root_entry_t; - - -disk_sector_t *new_image(char *bsfname) -{ - FILE *bsf; - disk_sector_t *img; - boot_sector_t boot_sec; - root_entry_t *root; - - if ((bsf = fopen(bsfname, "rb")) == NULL) - { - printf("Boot sector image file %s not found!\n", bsfname); - return NULL; - } - if (fread(&boot_sec, 1, SECTOR_SIZE, bsf) != SECTOR_SIZE) - { - printf("Unable to read boot sector image file %s!\n", bsfname); - fclose(bsf); - return NULL; - } - fclose(bsf); - - if ( (boot_sec.bytes_per_sector != SECTOR_SIZE) || - (boot_sec.sectors_per_cluster != SECTORS_PER_CLUSTER) || - (boot_sec.reserved_sectors != N_RESERVED) || - (boot_sec.n_fats != N_FATS) || - (boot_sec.n_root_entries != N_ROOT_ENTRIES) || - (boot_sec.n_sectors != SECTORS_PER_DISK) || - (boot_sec.media_type != MEDIA_TYPE) || - (boot_sec.sectors_per_fat != SECTORS_PER_FAT) || - (boot_sec.sectors_per_track != SECTORS_PER_TRACK) || - (boot_sec.n_heads != N_HEADS) || -// (boot_sec.signature != SIGNATURE) || - (boot_sec.end_signature != END_SIGNATURE) ) - { - printf("Invalid boot sector in file %s\n", bsfname); - return NULL; - } - - if ((img = (disk_sector_t *)malloc(SECTOR_SIZE * SECTORS_PER_DISK)) == NULL) - { - printf("Not enough memory!\n"); - return NULL; - } - - memset(img, 0, SECTOR_SIZE * SECTORS_PER_TRACK); - memcpy(img, &boot_sec, SECTOR_SIZE); - - root = (root_entry_t *)img[N_RESERVED + N_FATS * SECTORS_PER_FAT]; - strncpy(root->name, "REACTOS ", 11); - root->attribute = ATTR_VOLUME; - - return img; -} - - -void create_root_entry(root_entry_t *root, char *fname, - unsigned short cluster, unsigned long size) -{ - int i, j; - time_t t; - struct tm *localt; - - i = 0; - j = 0; - while ((fname[j] != '\0') && (fname[j] != '.') && (i < 8)) - { - root->name[i] = toupper(fname[j]); - i++; - j++; - } - while (i < 8) - { - root->name[i] = ' '; - i++; - } - if (fname[j] == '.') - { - i = 0; - j++; - while ((fname[j] != '\0') && (i < 3)) - { - root->extension[i] = toupper(fname[j]); - i++; - j++; - } - while (i < 3) - { - root->extension[i] = ' '; - i++; - } - } - else - { - i = 0; - while (i < 3) - { - root->extension[i] = ' '; - i++; - } - } - - root->attribute = ATTR_ARCHIVE; - t = time(0); - localt = localtime(&t); - root->time = (((localt->tm_hour & 0x001f) << 11) | - ((localt->tm_min & 0x003f) << 5) | - ((localt->tm_sec / 2) & 0x001f)); - root->date = ((((localt->tm_year - 80) & 0x007f) << 9) | - (((localt->tm_mon + 1) & 0x000f) << 5) | - (localt->tm_mday & 0x001f)); - root->cluster = cluster; - root->size = size; -} - - -void update_fat(unsigned char *fat, int cl_start, int cl_end) -{ - int i, k; - unsigned short *cl; - - for (i = cl_start; i < cl_end - 1; i++) - { - k = (i - 2) * 3 / 2; - cl = ((unsigned short *)&fat[k]); - if (i & 1) - { - *cl = (*cl & 0x000f) | (((i + 1) & 0x0fff) << 4); - } - else - { - *cl = (*cl & 0xf000) | ((i + 1) & 0x0fff); - } - } - k = (i - 2) * 3 / 2; - cl = ((unsigned short *)&fat[k]); - if (i & 1) - { - *cl = (*cl & 0x000f) | 0xfff0; - } - else - { - *cl = (*cl & 0xf000) | 0x0fff; - } -} - - -int copy_files(disk_sector_t *img, char *filenames[], int n_files) -{ - int i, k; - FILE *f; - int cl_start, cl_end; - unsigned char *fat1, *fat2; - root_entry_t *root; - unsigned long n, size; - - fat1 = (unsigned char *)img[N_RESERVED]; - fat2 = (unsigned char *)img[N_RESERVED + SECTORS_PER_FAT]; - root = (root_entry_t *)img[N_RESERVED + N_FATS * SECTORS_PER_FAT]; - - k = N_RESERVED + - N_FATS * SECTORS_PER_FAT + - N_ROOT_ENTRIES * ROOT_ENTRY_SIZE / SECTOR_SIZE; - - cl_end = 1; - - if (n_files > N_ROOT_ENTRIES) - { - n_files = N_ROOT_ENTRIES; - } - - for (i = 0; i < n_files; i++) - { - cl_start = cl_end + 1; - if ((f = fopen(filenames[i], "rb")) == NULL) - { - printf("Error opening file %s!", filenames[i]); - return 1; - } - - printf(" %s\n", filenames[i]); - - size = 0; - while ((n = fread(img[k], 1, SECTOR_SIZE, f)) > 0) - { - size += n; - cl_end++; - k++; - } - fclose(f); - - root++; - create_root_entry(root, filenames[i], cl_start, size); - - update_fat(fat1, cl_start, cl_end); - } - memcpy(fat2, fat1, SECTORS_PER_FAT * SECTOR_SIZE); - - return 0; -} - - -int write_image(disk_sector_t *img, char *imgname) -{ - FILE *f; - - if ((f = fopen(imgname, "rb")) != NULL) - { - printf("Image file %s already exists!\n", imgname); - fclose(f); - free(img); - return 1; - } - - f = fopen(imgname, "wb"); - if (fwrite(img, SECTOR_SIZE, SECTORS_PER_DISK, f) != SECTORS_PER_DISK) - { - printf("Unable to write image file %s\n!", imgname); - fclose(f); - free(img); - return 1; - } - fclose(f); - - free(img); - return 0; -} - - -int main(int argc, char *argv[]) -{ - disk_sector_t *img; - char *imgname; - char *bsfname; - char **filenames; - int n_files; - - if (argc < 4) - { - printf("Usage: mkflpimg <image> <boot sector> <source files>\n"); - return 1; - } - - imgname = argv[1]; - bsfname = argv[2]; - filenames = &argv[3]; - n_files = argc - 3; - - printf("Creating image ...\n"); - if ((img = new_image(bsfname)) == NULL) - { - return 1; - } - - printf("Copying files ...\n"); - - if (copy_files(img, filenames, n_files)) - { - return 1; - } - - printf("Writing image file ...\n"); - - if (write_image(img, imgname)) - { - return 1; - } - - printf("Finished.\n"); - - return 0; -} - Removed: trunk/reactos/tools/rcopy.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/tools/rcopy.c?rev=34106&vi…
============================================================================== --- trunk/reactos/tools/rcopy.c [iso-8859-1] (original) +++ trunk/reactos/tools/rcopy.c (removed) @@ -1,337 +1,0 @@ -#include <stdio.h> -#include <string.h> -#include <stdlib.h> -#include <sys/stat.h> -#include <utime.h> -#ifdef WIN32 -#include <io.h> -#include <dos.h> -#else -#include <sys/io.h> -#include <errno.h> -#include <sys/types.h> -#include <dirent.h> -#include <unistd.h> -#include <string.h> -#endif -#ifndef MAX_PATH -#define MAX_PATH 260 -#endif -#ifndef WIN32 -#define DIR_SEPARATOR_CHAR '/' -#define DIR_SEPARATOR_STRING "/" -#else -#define DIR_SEPARATOR_CHAR '\\' -#define DIR_SEPARATOR_STRING "\\" -#endif - -char * -make_absolute(char *absolute, char *path) -{ -#ifndef WIN32 - if (path[0] == DIR_SEPARATOR_CHAR) - { - strcpy(absolute, path); - } - else - { - getcwd(absolute, MAX_PATH); - strcat(absolute, DIR_SEPARATOR_STRING); - strcat(absolute, path); - } -#else - _fullpath(absolute, path, MAX_PATH); -#endif - - return absolute; -} - -char* convert_path(char* origpath) -{ - char* newpath; - int i; - - //newpath = strdup(origpath); - newpath = malloc(strlen(origpath)+1); - strcpy(newpath, origpath); - - i = 0; - while (newpath[i] != 0) - { -#ifdef UNIX_PATHS - if (newpath[i] == '\\') - { - newpath[i] = '/'; - } -#else -#ifdef DOS_PATHS - if (newpath[i] == '/') - { - newpath[i] = '\\'; - } -#endif -#endif - i++; - } - return(newpath); -} - -#define TRANSFER_SIZE (65536) - -static void -copy_file(char* path1, char* path2) -{ - FILE* in; - FILE* out; - char* buf; - int n_in; - int n_out; - struct stat st_buffer; - struct utimbuf ut_buffer; - - in = fopen(path1, "rb"); - if (in == NULL) - { - perror("Cannot open input file"); - exit(1); - } - - out = fopen(path2, "wb"); - if (out == NULL) - { - perror("Cannot open output file"); - fclose(in); - exit(1); - } - - buf = malloc(TRANSFER_SIZE); - while (!feof(in)) - { - n_in = fread(buf, 1, TRANSFER_SIZE, in); - n_out = fwrite(buf, 1, n_in, out); - if (n_in != n_out) - { - perror("Failed to write to output file\n"); - free(buf); - fclose(in); - fclose(out); - exit(1); - } - } - free(buf); - fclose(in); - fclose(out); - - if (stat(path2, &st_buffer) >= 0) - { - ut_buffer.actime = st_buffer.st_atime; - - if (stat(path1, &st_buffer) >= 0) - { - ut_buffer.modtime = st_buffer.st_mtime; - utime(path2, &ut_buffer); - } - } - -} - -#ifdef WIN32 - -static void -copy_directory (char *path1, char *path2) -{ - struct _finddata_t f; - int findhandle; - char buf[MAX_PATH]; - char tobuf[MAX_PATH]; - - strcpy(buf, path1); - if (path1[strlen(path1) - 1] != DIR_SEPARATOR_CHAR) - strcat(buf, DIR_SEPARATOR_STRING); - strcat(buf, "*.*"); - findhandle =_findfirst(buf, &f); - if (findhandle != 0) - { - do - { - if ((f.attrib & _A_SUBDIR) == 0 && f.name[0] != '.') - { - // Convert to absolute path - make_absolute(buf, path1); - if (path1[strlen(path1) - 1] != DIR_SEPARATOR_CHAR) - strcat(buf, DIR_SEPARATOR_STRING); - strcat(buf, f.name); - - //printf("copying file %s\n", buf); - if (path2[strlen(path2) - 1] == DIR_SEPARATOR_CHAR) - { - strcpy(tobuf, path2); - strcat(tobuf, f.name); - } - else - { - strcpy(tobuf, path2); - strcat(tobuf, DIR_SEPARATOR_STRING); - strcat(tobuf, f.name); - } - copy_file(buf, tobuf); - } - else - { - //printf("skipping directory '%s'\n", f.name); - } - } - while (_findnext(findhandle, &f) == 0); - - _findclose(findhandle); - } -} - -#else -/* Linux version */ - -static int -is_reg (char *path, char *fn) -{ - char buf[MAX_PATH]; - char buf2[MAX_PATH]; - struct stat sbuf; - - strcpy(buf, path); - if (buf[strlen(buf)-1] != '/') - strcat(buf, "/"); - strcat(buf, fn); - - make_absolute(buf2, buf); - - if (stat(buf2, &sbuf) == -1) - return 0; - else { - if (S_ISREG(sbuf.st_mode)) - return 1; - else - return 0; - } -} - -static void -copy_directory (char *path1, char *path2) -{ - DIR *dirp; - struct dirent *entry; - struct stat stbuf; - char buf[MAX_PATH]; - char tobuf[MAX_PATH]; - char err[400]; - - dirp = opendir(path1); - - if (dirp != NULL) - { - while ((entry = readdir (dirp)) != NULL) - { - if (strcmp(entry->d_name, ".") == 0 || strcmp(entry->d_name, "..") == 0) - continue; // skip self and parent - - if (entry->d_type == DT_REG || is_reg(path1, entry->d_name)) // normal file - { - // Convert to absolute path - make_absolute(buf, path1); - if (path1[strlen(path1) - 1] != DIR_SEPARATOR_CHAR) - strcat(buf, DIR_SEPARATOR_STRING); - strcat(buf, entry->d_name); - if (stat(buf, &stbuf) == -1) - { - sprintf(err, "Can't access '%s' (%s)\n", buf, strerror(errno)); - perror(err); - exit(1); - return; - } - - //printf("copying file '%s'\n", entry->d_name); - if (path2[strlen(path2) - 1] == DIR_SEPARATOR_CHAR) - { - strcpy(tobuf, path2); - strcat(tobuf, entry->d_name); - } - else - { - strcpy(tobuf, path2); - strcat(tobuf, DIR_SEPARATOR_STRING); - strcat(tobuf, entry->d_name); - } - copy_file(buf, tobuf); - } - else - { - //printf("skipping directory '%s'\n", entry->d_name); - } - } - closedir (dirp); - } - else - { - sprintf(err, "Can't open %s\n", path1); - perror(err); - exit(1); - return; - } -} - -#endif - -static int -is_directory(char *path) -{ - struct stat stbuf; - char buf[MAX_PATH]; - - // Convert to absolute path - make_absolute(buf, path); - if (stat(buf, &stbuf) == -1) - { - /* Assume a destination file */ - return 0; - } - if (S_ISDIR(stbuf.st_mode)) - return 1; - else - return 0; -} - -int main(int argc, char* argv[]) -{ - char* path1; - char* path2; - int dir1; - int dir2; - - if (argc != 3) - { - fprintf(stderr, "Wrong argument count\n"); - exit(1); - } - - path1 = convert_path(argv[1]); - path2 = convert_path(argv[2]); - - dir1 = is_directory(path1); - dir2 = is_directory(path2); - - if ((dir1 && !dir2) || (!dir1 && dir2)) - { - perror("None or both paramters must be a directory\n"); - exit(1); - } - - if (dir1) - { - copy_directory(path1, path2); - } - else - { - copy_file(path1, path2); - } - - exit(0); -} Removed: trunk/reactos/tools/rdel.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/tools/rdel.c?rev=34106&vie…
============================================================================== --- trunk/reactos/tools/rdel.c [iso-8859-1] (original) +++ trunk/reactos/tools/rdel.c (removed) @@ -1,101 +1,0 @@ -/* $Id$ - * COPYRIGHT: See COPYING in the top level directory - * PROGRAMMER: Rex Jolliff (rex(a)lvcablemodem.com) - * PURPOSE: Platform independent delete command - */ - -#include <dirent.h> -#include <errno.h> -#include <limits.h> -#include <stdio.h> -#include <string.h> -#include <stdlib.h> -#ifdef __WIN32__ -# include <io.h> -#endif -#include <sys/types.h> -#include <sys/stat.h> - -void -convertPath (char * pathToConvert) -{ - while (*pathToConvert != 0) - { - if (*pathToConvert == '\\') - { - *pathToConvert = '/'; - } - pathToConvert++; - } -} - -#if 0 -void -getDirectory (const char *filename, char * directorySpec) -{ - int lengthOfDirectory; - - if (strrchr (filename, '/') != 0) - { - lengthOfDirectory = strrchr (filename, '/') - filename; - strncpy (directorySpec, filename, lengthOfDirectory); - directorySpec [lengthOfDirectory] = '\0'; - } - else - { - strcpy (directorySpec, "."); - } -} -#endif - -void -getFilename (const char *filename, char * fileSpec) -{ - if (strrchr (filename, '/') != 0) - { - strcpy (fileSpec, strrchr (filename, '/') + 1); - } - else - { - strcpy (fileSpec, filename); - } -} - -int -main (int argc, char* argv[]) -{ - int justPrint = 0; - int idx; - int returnCode; - - for (idx = 1; idx < argc; idx++) - { - convertPath (argv [idx]); - - if (justPrint) - { - printf ("delete %s\n", argv [idx]); - } - else - { -#ifdef __WIN32__ - _chmod (argv [idx], _S_IREAD | _S_IWRITE); -#else - chmod (argv [idx], 0666); -#endif - returnCode = remove (argv [idx]); - if (returnCode != 0 && errno != ENOENT) - { - /* Continue even if there is errors */ -#if 0 - printf ("Unlink of %s failed. Unlink returned %d.\n", - argv [idx], - returnCode); - return returnCode; -#endif - } - } - } - - return 0; -} Removed: trunk/reactos/tools/regtests.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/tools/regtests.c?rev=34106…
============================================================================== --- trunk/reactos/tools/regtests.c [iso-8859-1] (original) +++ trunk/reactos/tools/regtests.c (removed) @@ -1,870 +1,0 @@ -/* - * Generate a file with test registrations from a list - * of files in a directory. - * Casper S. Hornstrup <chorns(a)users.sourceforge.net> - */ - -#include <stdio.h> -#include <fcntl.h> -#include <sys/stat.h> -#include <stdlib.h> -#include <string.h> -#include <ctype.h> - -#ifdef WIN32 -#include <io.h> -#include <dos.h> -#else -#include <sys/io.h> -#include <errno.h> -#include <sys/types.h> -#include <dirent.h> -#include <unistd.h> -#endif -#ifndef MAX_PATH -#define MAX_PATH 260 -#endif -#ifndef WIN32 -#define DIR_SEPARATOR_CHAR '/' -#define DIR_SEPARATOR_STRING "/" -#else -#define DIR_SEPARATOR_CHAR '\\' -#define DIR_SEPARATOR_STRING "\\" -#endif - -static FILE *out; -static char *path; -static char *file; -static char *makefile; -static char *exestubfile; - -static char* -convert_path(char* origpath) -{ - char* newpath; - int i; - - /* for no good reason, i'm having trouble getting gcc to link strdup */ - //newpath = strdup(origpath); - newpath = malloc(strlen(origpath)+1); - strcpy(newpath, origpath); - - i = 0; - while (newpath[i] != 0) - { -#ifndef WIN32 - if (newpath[i] == '\\') - { - newpath[i] = '/'; - } -#else -#ifdef WIN32 - if (newpath[i] == '/') - { - newpath[i] = '\\'; - } -#endif -#endif - i++; - } - return(newpath); -} - -static void -write_line(char *line) -{ - int n_out; - char buf[200]; - - memset(buf, 0, sizeof(buf)); - strcpy(buf, line); - /* Terminate the line */ - buf[strlen(buf)] = '\r'; - buf[strlen(buf)] = '\n'; - - n_out = fwrite(&buf[0], 1, strlen(buf), out); -} - -static void -change_extension(char *filenamebuffer, - char *filename, - char *newextension) -{ - char *ptr; - - if (newextension == NULL) - { - strcpy(filenamebuffer, filename); - return; - } - - ptr = strrchr(filename, '.'); - if (ptr != NULL) - { - strncpy(filenamebuffer, filename, ptr - filename); - filenamebuffer[ptr - filename] = 0; - strcat(filenamebuffer, newextension); - } - else - { - strcpy(filenamebuffer, filename); - strcat(filenamebuffer, newextension); - } -} - -static void -get_test_name(char *filename, - char *testname) -{ - int i; - - strcpy(testname, filename); - - i = strlen(testname); - while (i > 0 && testname[i] != '.') - { - i--; - } - if (i > 0) - { - testname[i] = 0; - } - - /* Make a capital first letter and make all other letters lower case */ - testname[0] = toupper(testname[0]); - if (!((testname[0] >= 'A' && testname[0] <= 'Z') || - (testname[0] >= '0' && testname[0] <= '9'))) - { - testname[0] = '_'; - } - i = 1; - while (i < strlen(testname)) - { - testname[i] = tolower(testname[i]); - if (!((testname[i] >= 'a' && testname[i] <= 'z') || - (testname[i] >= '0' && testname[i] <= '9'))) - { - testname[i] = '_'; - } - i++; - } -} - -/* - * filename - name of file to make registrations for - * type - type of registration (0 = prototype, 1 = call, 2 = makefile) - */ -static void -register_test(char *filename, - int type) -{ - char ext[100]; - char testname[100]; - char call[100]; - char regtest[100]; - char filenamebuffer[MAX_PATH]; - int i; - - i = strlen(filename); - while (i > 0 && filename[i] != '.') - { - i--; - } - if (i > 0) - { - memset(ext, 0, sizeof(ext)); - strncpy(&ext[0], &filename[i], strlen(&filename[i])); - - if (strcasecmp(ext, ".c") != 0) - { - return; - } - } - else - { - return; - } - - memset(testname, 0, sizeof(testname)); - get_test_name(filename, testname); - - if (type == 0) - { - sprintf(regtest, "extern int %sTest(int Command, char *Buffer);", testname); - write_line(regtest); - } - else if (type == 1) - { - sprintf(call, "%sTest", testname); - sprintf(regtest, " AddTest((TestRoutine)%s);", call); - write_line(regtest); - } - else if (type == 2) - { - change_extension(filenamebuffer, filename, ".o"); - sprintf(regtest, "%s \\", filenamebuffer); - write_line(regtest); - } -} - -#ifdef WIN32 - -/* Win32 version */ - -static void -make_file_list (int type) -{ - struct _finddata_t f; - int findhandle; - char searchbuf[MAX_PATH]; - - strcpy(searchbuf, path); - strcat(searchbuf, "*.*"); - findhandle =_findfirst(searchbuf, &f); - if (findhandle != -1) - { - do - { - if (f.attrib & _A_SUBDIR) - { - /* Skip subdirectories */ - continue; - } - - register_test(f.name, type); - } - while (_findnext(findhandle, &f) == 0); - _findclose(findhandle); - } -} - -#else - -/* Linux version */ -static void -make_file_list (int type) -{ - DIR *dirp; - struct dirent *entry; - struct stat stbuf; - char buf[MAX_PATH]; - -#ifdef HAVE_D_TYPE - dirp = opendir(path); - if (dirp != NULL) - { - while ((entry = readdir(dirp)) != NULL) - { - if (strcmp(entry->d_name, ".") == 0 || strcmp(entry->d_name, "..") == 0) - continue; // skip self and parent - - if (entry->d_type == DT_REG) // normal file - { - // Check for an absolute path - if (path[0] == DIR_SEPARATOR_CHAR) - { - strcpy(buf, path); - strcat(buf, DIR_SEPARATOR_STRING); - strcat(buf, entry->d_name); - } - else - { - getcwd(buf, sizeof(buf)); - strcat(buf, DIR_SEPARATOR_STRING); - strcat(buf, path); - strcat(buf, entry->d_name); - } - - if (stat(buf, &stbuf) == -1) - { - printf("Can't access '%s' (%s)\n", buf, strerror(errno)); - return; - } - - if (S_ISDIR(stbuf.st_mode)) - { - /* Skip subdirectories */ - continue; - } - - register_test(entry->d_name, type); - } - } - closedir(dirp); - } - else - { - printf("Can't open %s\n", path); - return; - } - -#else - - dirp = opendir(path); - if (dirp != NULL) - { - while ((entry = readdir(dirp)) != NULL) - { - if (strcmp(entry->d_name, ".") == 0 || strcmp(entry->d_name, "..") == 0) - continue; // skip self and parent - - // Check for an absolute path - if (path[0] == DIR_SEPARATOR_CHAR) - { - strcpy(buf, path); - strcat(buf, DIR_SEPARATOR_STRING); - strcat(buf, entry->d_name); - } - else - { - getcwd(buf, sizeof(buf)); - strcat(buf, DIR_SEPARATOR_STRING); - strcat(buf, path); - strcat(buf, entry->d_name); - } - - if (stat(buf, &stbuf) == -1) - { - printf("Can't access '%s' (%s)\n", buf, strerror(errno)); - return; - } - - if (S_ISDIR(stbuf.st_mode)) - { - /* Skip subdirectories */ - continue; - } - - register_test(entry->d_name, type); - } - closedir(dirp); - } - else - { - printf("Can't open %s\n", path); - return; - } - -#endif -} - -#endif - -static int -is_file_changed(char *filename, - char *content) -{ - FILE *file; - int size; - int n; - char *filecontent; - - file = fopen(filename, "rb"); - if (file == NULL) - { - return 1; - } - - fseek(file, 0, SEEK_END); - size = ftell(file); - fseek(file, 0, SEEK_SET); - if (size <= 0) - { - fclose(file); - return 1; - } - filecontent = malloc(size); - if (filecontent == NULL) - { - fclose(file); - return 1; - } - - n = fread(filecontent, 1, size, file); - - if (n != strlen(content)) - { - free(filecontent); - fclose(file); - return 1; - } - - if (strcmp(content, filecontent) != 0) - { - free(filecontent); - fclose(file); - return 1; - } - - free(filecontent); - - fclose(file); - - return 0; -} - -static int -write_file_if_changed(char *filename, - char *content) -{ - FILE *file; - int n; - - if (is_file_changed(filename, content) == 0) - { - return 0; - } - - file = fopen(filename, "wb"); - if (file == NULL) - { - return 1; - } - - n = fwrite(content, 1, strlen(content), file); - - fclose(file); - - return 0; -} - -static char EXESTUB[] = - "/* This file is autogenerated. */\n" - "\n" - "#include <windows.h>\n" - "#include \"regtests.h\"\n" - "\n" - "void\n" - "ConsoleWrite(char *Buffer)\n" - "{\n" - " printf(Buffer);\n" - "}\n" - "\n" - "int\n" - "mainCRTStartup(HANDLE hInstance,\n" - " HANDLE hPrevInstance,\n" - " LPSTR lpszCmdParam,\n" - " int nCmdShow)\n" - "{\n" - " InitializeTests();\n" - " RegisterTests();\n" - " SetupOnce();\n" - " PerformTests(ConsoleWrite, NULL);\n" - " _ExitProcess(0);\n" - " return 0;\n" - "}\n"; - -static char STUBS_HEADER[] = - "/* This file is autogenerated. */\n" - "passthrough:\n" - " call _FrameworkGetHook@4\n" - " test %eax, %eax\n" - " je .return\n" - " jmp *%eax\n" - ".return:\n" - " /* This will most likely corrupt the stack */\n" - " ret\n" - "\n"; - -static char HOOKS_HEADER[] = - "/* This file is autogenerated. */\n" - "#include <windows.h>\n" - "#include \"regtests.h\"\n" - "\n" - "API_DESCRIPTION ExternalDependencies[] =\n" - "{\n"; - -static char HOOKS_FOOTER[] = - "};\n" - "\n" - "#define ExternalDependencyCount %d\n" - "ULONG MaxExternalDependency = ExternalDependencyCount - 1;\n"; - -static char HELP[] = - "REGTESTS path file makefile [-e exestubfile]\n" - "REGTESTS -s stublistfile stubsfile hooksfile\n" - "\n" - " path Path to files\n" - " file Registration file to create\n" - " makefile Makefile to create\n" - " exestubfile Optional stub for running tests in the build environment\n" - " stublistfile File with descriptions of stubs\n" - " stubsfile File with stubs to create\n" - " hooksfile File with hooks to create\n"; - -#define INPUT_BUFFER_SIZE 255 - -void -write_stubs_header(FILE * out) -{ - fputs(STUBS_HEADER, out); -} - -void -write_hooks_header(FILE * out) -{ - fputs(HOOKS_HEADER, out); -} - -void -write_hooks_footer(FILE *hooks_out, unsigned long nr_stubs) -{ - fprintf(hooks_out, HOOKS_FOOTER, nr_stubs); -} - -char * -get_symbolname(char *decoratedname) -{ - char buf[300]; - - if (decoratedname[0] == '@') - return strdup(decoratedname); - strcpy(buf, "_"); - strcat(buf, decoratedname); - return strdup(buf); -} - -char * -get_undecorated_name(char *buf, - char *decoratedname) -{ - int start = 0; - int end = 0; - - while (start < strlen(decoratedname) && decoratedname[start] == '@') - { - start++; - } - strcpy(buf, &decoratedname[start]); - end = strlen(buf) - 1; - while (end > 0 && isdigit(buf[end])) - { - end--; - } - if (buf[end] == '@') - { - buf[end] = 0; - } - return buf; -} - -char * -get_forwarded_export(char *forwardedexport) -{ - char buf[300]; - - if (forwardedexport == NULL) - { - strcpy(buf, "NULL"); - } - else - { - sprintf(buf, "\"%s\"", forwardedexport); - } - return strdup(buf); -} - -void -write_stub(FILE *stubs_out, FILE *hooks_out, char *dllname, - char *decoratedname_and_forward, unsigned int stub_index) -{ - char buf[300]; - char *p; - char *decoratedname = NULL; - char *forwardedexport = NULL; - char *symbolname = NULL; - - p = strtok(decoratedname_and_forward, "="); - if (p != NULL) - { - decoratedname = p; - - p = strtok(NULL, "="); - forwardedexport = p; - } - else - { - decoratedname = decoratedname_and_forward; - forwardedexport = decoratedname_and_forward; - } - - symbolname = get_symbolname(decoratedname); - fprintf(stubs_out, ".globl %s\n", symbolname); - fprintf(stubs_out, "%s:\n", symbolname); - free(symbolname); - fprintf(stubs_out, " pushl $%d\n", stub_index); - fprintf(stubs_out, " jmp passthrough\n"); - fprintf(stubs_out, "\n"); - forwardedexport = get_forwarded_export(forwardedexport); - fprintf(hooks_out, " {\"%s\", \"%s\", %s, NULL, NULL},\n", - dllname, - get_undecorated_name(buf, decoratedname), - forwardedexport); - free(forwardedexport); -} - -void -create_stubs_and_hooks( - FILE *in, - FILE *stubs_out, - FILE *hooks_out) -{ - char line[INPUT_BUFFER_SIZE]; - char *s, *start; - char *dllname; - char *decoratedname_and_forward; - int stub_index; - - write_stubs_header(stubs_out); - - write_hooks_header(hooks_out); - - /* - * Scan the database. The database is a text file; each - * line is a record, which contains data for one stub. - * Each record has two columns: - * - * DLLNAME (e.g. ntdll.dll) - * DECORATED NAME (e.g. NtCreateProcess@32, @InterlockedIncrement@4 or printf) - */ - stub_index = 0; /* First stub has index zero */ - - for ( - ; - /* Go on until EOF or read zero bytes */ - ((!feof(in)) && (fgets(line, sizeof line, in) != NULL)); - /* Next stub index */ - ) - { - /* - * Ignore leading blanks - */ - for( start = line; *start && isspace(*start); start++ ); - - /* - * Strip comments, eols - */ - for( s = start; *s && !strchr("#\n\r", *s); s++ ); - - *s = '\0'; - - /* - * Remove trailing blanks. Backup off the char that ended our - * run before. - */ - for( s--; s > start && isspace(*s); s-- ) *s = '\0'; - - /* - * Skip empty lines - */ - if (s > start) - { - /* Extract the DLL name */ - dllname = (char *) strtok(start, " \t"); - if (dllname != NULL && strlen(dllname) > 0) - { - /* - * Extract the decorated function name and possibly forwarded export. - * Format: - * decoratedname=forwardedexport (no DLL name) - */ - decoratedname_and_forward = (char *) strtok(NULL, " \t"); - /* Extract the argument count */ - - /* Something went wrong finding the separator ... - * print an error and bail. */ - if( !decoratedname_and_forward ) { - fprintf - ( stderr, - "Could not find separator between decorated " - "function name and dll name.\n" - "Format entries as <dllname> <import>\n" - "Legal comments start with #\n"); - exit(1); - } - - write_stub(stubs_out, hooks_out, dllname, decoratedname_and_forward, stub_index); - stub_index++; - } - } - } - - write_hooks_footer(hooks_out, stub_index); -} - -int run_stubs(int argc, - char **argv) -{ - FILE *in; - FILE *stubs_out; - FILE *hooks_out; - - in = fopen(argv[2], "rb"); - if (in == NULL) - { - perror("Failed to open stub description input file"); - return 1; - } - - stubs_out = fopen(argv[3], "wb"); - if (stubs_out == NULL) - { - perror("Failed to open stubs output file"); - return 1; - } - - hooks_out = fopen(argv[4], "wb"); - if (hooks_out == NULL) - { - perror("Failed to open hooks output file"); - return 1; - } - - create_stubs_and_hooks(in, stubs_out, hooks_out); - - fclose(stubs_out); - fclose(hooks_out); - - return 0; -} - -int run_registrations(int argc, - char **argv) -{ - char buf[MAX_PATH]; - int i; - - if (argc < 4) - { - puts(HELP); - return 1; - } - - strcpy(buf, convert_path(argv[1])); - if (buf[strlen(buf)] != DIR_SEPARATOR_CHAR) - { - int i = strlen(buf); - buf[strlen(buf)] = DIR_SEPARATOR_CHAR; - buf[i + 1] = 0; - } - path = buf; - if (path[0] == 0) - { - printf("Missing path\n"); - return 1; - } - - file = convert_path(argv[2]); - if (file[0] == 0) - { - printf("Missing file\n"); - return 1; - } - - makefile = convert_path(argv[3]); - if (makefile[0] == 0) - { - printf("Missing makefile\n"); - return 1; - } - - exestubfile = NULL; - for (i = 4; i < argc; i++) - { - if (argv[i][0] == '-') - { - if (argv[i][1] == 'e') - { - exestubfile = convert_path(argv[++i]); - if (exestubfile[0] == 0) - { - printf("Missing exestubfile\n"); - return 1; - } - } - else - { - printf("Unknown switch -%c\n", argv[i][1]); - return 1; - } - } - } - - - /* Registration file */ - out = fopen(file, "wb"); - if (out == NULL) - { - perror("Cannot create output file"); - return 1; - } - - write_line("/* This file is autogenerated. */"); - write_line(""); - write_line("typedef int (*TestRoutine)(int Command, char *Buffer);"); - write_line(""); - - make_file_list(0); - - write_line(""); - write_line("extern void AddTest(TestRoutine Routine);"); - write_line(""); - write_line("void RegisterTests()"); - write_line("{"); - - make_file_list(1); - - write_line("}"); - - fclose(out); - - - /* Makefile */ - out = fopen(makefile, "wb"); - if (out == NULL) - { - perror("Cannot create output makefile"); - return 1; - } - - write_line("# This file is autogenerated."); - write_line(""); - write_line("TESTS = \\"); - - make_file_list(2); - - write_line(""); - - fclose(out); - - /* Executable stubfile */ - if (exestubfile != NULL) - { - if (write_file_if_changed(exestubfile, EXESTUB) != 0) - { - perror("Cannot create output executable stubfile"); - return 1; - } - } - - return 0; -} - -int main(int argc, - char **argv) -{ - if (argc < 2) - { - puts(HELP); - return 1; - } - - if (strlen(argv[1]) > 1 && argv[1][0] == '-' && argv[1][1] == 's') - { - return run_stubs(argc, argv); - } - else - { - return run_registrations(argc, argv); - } -} Removed: trunk/reactos/tools/rline.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/tools/rline.c?rev=34106&vi…
============================================================================== --- trunk/reactos/tools/rline.c [iso-8859-1] (original) +++ trunk/reactos/tools/rline.c (removed) @@ -1,136 +1,0 @@ -/* - * Copy a text file with end-of-line character transformation (EOL) - * - * Usage: rline input-file output-file - */ -#include <sys/stat.h> -#include <stdio.h> -#include <string.h> -#include <stdlib.h> - -char* convert_path(char* origpath) -{ - char* newpath; - int i; - - newpath = strdup(origpath); - - i = 0; - while (newpath[i] != 0) - { -#ifdef UNIX_PATHS - if (newpath[i] == '\\') - { - newpath[i] = '/'; - } -#else -#ifdef DOS_PATHS - if (newpath[i] == '/') - { - newpath[i] = '\\'; - } -#endif -#endif - i++; - } - return(newpath); -} - -int -fsize (FILE * f) -{ - struct stat st; - int fh = fileno (f); - - if (fh < 0 || fstat (fh, &st) < 0) - return -1; - return (int) st.st_size; -} - -int main(int argc, char* argv[]) -{ - char* path1; - char* path2; - FILE* in; - FILE* out; - char* in_buf; - int in_size; - int in_ptr; - int linelen; - int n_in; - int n_out; - char eol_buf[2]; - - /* Terminate the line with windows EOL characters (CRLF) */ - eol_buf[0] = '\r'; - eol_buf[1] = '\n'; - - if (argc != 3) - { - fprintf(stderr, "Wrong argument count\n"); - exit(1); - } - - path1 = convert_path(argv[1]); - path2 = convert_path(argv[2]); - - in = fopen(path1, "rb"); - if (in == NULL) - { - perror("Cannot open input file"); - exit(1); - } - - in_size = fsize(in); - in_buf = malloc(in_size); - if (in_buf == NULL) - { - perror("Not enough free memory"); - fclose(in); - exit(1); - } - - out = fopen(path2, "wb"); - if (out == NULL) - { - perror("Cannot open output file"); - fclose(in); - exit(1); - } - - /* Read it all in */ - n_in = fread(in_buf, 1, in_size, in); - - in_ptr = 0; - while (in_ptr < in_size) - { - linelen = 0; - - while ((in_ptr + linelen < in_size) && (in_buf[in_ptr + linelen] != '\r') && (in_buf[in_ptr + linelen] != '\n')) - { - linelen++; - } - if (linelen > 0) - { - n_out = fwrite(&in_buf[in_ptr], 1, linelen, out); - in_ptr += linelen; - } - /* Terminate the line */ - n_out = fwrite(&eol_buf[0], 1, sizeof(eol_buf), out); - - if ((in_ptr < in_size) && (in_buf[in_ptr] == '\r')) - { - in_ptr++; - } - - if ((in_ptr < in_size) && (in_buf[in_ptr] == '\n')) - { - in_ptr++; - } - } - - free(in_buf); - fclose(in); - - exit(0); -} Removed: trunk/reactos/tools/rmkdir.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/tools/rmkdir.c?rev=34106&v…
============================================================================== --- trunk/reactos/tools/rmkdir.c [iso-8859-1] (original) +++ trunk/reactos/tools/rmkdir.c (removed) @@ -1,110 +1,0 @@ -#include <stdio.h> -#include <string.h> -#include <stdlib.h> -#include <ctype.h> -#ifdef WIN32 -#include <direct.h> -#else -#include <unistd.h> -#include <sys/stat.h> -#include <sys/types.h> -#endif - -#define WIN_SEPARATOR_CHAR '\\' -#define WIN_SEPARATOR_STRING "\\" -#define NIX_SEPARATOR_CHAR '/' -#define NIX_SEPARATOR_STRING "/" - -#ifdef WIN32 -#define DIR_SEPARATOR_CHAR WIN_SEPARATOR_CHAR -#define DIR_SEPARATOR_STRING WIN_SEPARATOR_STRING -#define BAD_SEPARATOR_CHAR NIX_SEPARATOR_CHAR -#define MKDIR(s) mkdir(s) -#else -#define DIR_SEPARATOR_CHAR NIX_SEPARATOR_CHAR -#define DIR_SEPARATOR_STRING NIX_SEPARATOR_STRING -#define BAD_SEPARATOR_CHAR WIN_SEPARATOR_CHAR -#define MKDIR(s) mkdir(s,0755) -#endif - -char* -convert_path(char* origpath) -{ - char* newpath; - int i; - - newpath=malloc(strlen(origpath)+1); - strcpy(newpath,origpath); - - i = 0; - while (newpath[i] != 0) - { - if (newpath[i] == BAD_SEPARATOR_CHAR) - { - newpath[i] = DIR_SEPARATOR_CHAR; - } - i++; - } - return(newpath); -} - -#define TRANSFER_SIZE (65536) - -int mkdir_p(char* path) -{ - if (chdir(path) == 0) - { - return(0); - } - if (MKDIR(path) != 0) - { - perror("Failed to create directory"); - exit(1); - } - if (chdir(path) != 0) - { - perror("Failed to change directory"); - exit(1); - } - return(0); -} - -int main(int argc, char* argv[]) -{ - char* path1; - char* csec; - char buf[256]; - - if (argc != 2) - { - fprintf(stderr, "Too many arguments\n"); - exit(1); - } - - path1 = convert_path(argv[1]); - - if (isalpha(path1[0]) && path1[1] == ':' && path1[2] == DIR_SEPARATOR_CHAR) - { - csec = strtok(path1, DIR_SEPARATOR_STRING); - sprintf(buf, "%s\\", csec); - chdir(buf); - csec = strtok(NULL, DIR_SEPARATOR_STRING); - } - else if (path1[0] == DIR_SEPARATOR_CHAR) - { - chdir(DIR_SEPARATOR_STRING); - csec = strtok(path1, DIR_SEPARATOR_STRING); - } - else - { - csec = strtok(path1, DIR_SEPARATOR_STRING); - } - - while (csec != NULL) - { - mkdir_p(csec); - csec = strtok(NULL, DIR_SEPARATOR_STRING); - } - - exit(0); -} Removed: trunk/reactos/tools/rrmdir.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/tools/rrmdir.c?rev=34106&v…
============================================================================== --- trunk/reactos/tools/rrmdir.c [iso-8859-1] (original) +++ trunk/reactos/tools/rrmdir.c (removed) @@ -1,95 +1,0 @@ -/* $Id$ - * COPYRIGHT: See COPYING in the top level directory - * PROGRAMMER: Rex Jolliff (rex(a)lvcablemodem.com) - * Casper S. Hornstrup (chorns(a)users.sourceforge.net) - * PURPOSE: Platform independent remove directory command - */ - -#include <dirent.h> -#include <errno.h> -#include <limits.h> -#include <stdio.h> -#include <string.h> -#include <stdlib.h> -#ifndef _MSC_VER -#include <unistd.h> -#endif - -void -convertPath (char * pathToConvert) -{ - while (*pathToConvert != 0) - { - if (*pathToConvert == '\\') - { - *pathToConvert = '/'; - } - pathToConvert++; - } -} - -#if 0 -void -getDirectory (const char *filename, char * directorySpec) -{ - int lengthOfDirectory; - - if (strrchr (filename, '/') != 0) - { - lengthOfDirectory = strrchr (filename, '/') - filename; - strncpy (directorySpec, filename, lengthOfDirectory); - directorySpec [lengthOfDirectory] = '\0'; - } - else - { - strcpy (directorySpec, "."); - } -} - -void -getFilename (const char *filename, char * fileSpec) -{ - if (strrchr (filename, '/') != 0) - { - strcpy (fileSpec, strrchr (filename, '/') + 1); - } - else - { - strcpy (fileSpec, filename); - } -} -#endif - -int -main (int argc, char* argv[]) -{ - int justPrint = 0; - int idx; - int returnCode; - - for (idx = 1; idx < argc; idx++) - { - convertPath (argv [idx]); - - if (justPrint) - { - printf ("remove %s\n", argv [idx]); - } - else - { - returnCode = rmdir (argv [idx]); - if (returnCode != 0 && errno != ENOENT) - { - /* Continue even if there is errors */ -#if 0 - printf ("Rmdir of %s failed. Rmdir returned %d.\n", - argv [idx], - returnCode); - return returnCode; -#endif - } - } - } - - return 0; -} Removed: trunk/reactos/tools/rtouch.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/tools/rtouch.c?rev=34106&v…
============================================================================== --- trunk/reactos/tools/rtouch.c [iso-8859-1] (original) +++ trunk/reactos/tools/rtouch.c (removed) @@ -1,86 +1,0 @@ -#include <sys/types.h> -#include <sys/stat.h> - -#ifdef WIN32 -#include <sys/utime.h> -#include <time.h> -#else -#include <sys/time.h> -#include <unistd.h> -#endif -#include <stdlib.h> -#include <string.h> - -#include <fcntl.h> -#include <stdio.h> - -char* convert_path(char* origpath) -{ - char* newpath; - int i; - - //newpath = (char *)strdup(origpath); - newpath=malloc(strlen(origpath)+1); - strcpy(newpath,origpath); - - i = 0; - while (newpath[i] != 0) - { -#ifdef UNIX_PATHS - if (newpath[i] == '\\') - { - newpath[i] = '/'; - } -#else -#ifdef DOS_PATHS - if (newpath[i] == '/') - { - newpath[i] = '\\'; - } -#endif -#endif - i++; - } - return(newpath); -} - -int main(int argc, char* argv[]) -{ - char* path; - int id; -#ifdef WIN32 - time_t now; - struct utimbuf fnow; -#endif - - if (argc != 2) - { - fprintf(stderr, "Wrong number of arguments.\n"); - exit(1); - } - - path = convert_path(argv[1]); - id = open(path, S_IWRITE, S_IRUSR | S_IWUSR); - if (id < 0) - { - id = open(path, O_WRONLY | O_CREAT, S_IRUSR | S_IWUSR); - if (id < 0) - { - fprintf(stderr, "Cannot create file.\n"); - exit(1); - } - } - - close(id); - -#ifdef WIN32 - now = time(NULL); - fnow.actime = now; - fnow.modtime = now; - (int) utime(path, &fnow); -#else - (int) utimes(path, NULL); -#endif - - exit(0); -}
16 years, 6 months
1
0
0
0
← Newer
1
...
9
10
11
12
13
14
15
...
44
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
Results per page:
10
25
50
100
200