diff --git a/base/applications/rapps/rapps/7zip.txt b/base/applications/rapps/rapps/7zip.txt
index 40499b19307..5f52e2a78f0 100644
--- a/base/applications/rapps/rapps/7zip.txt
+++ b/base/applications/rapps/rapps/7zip.txt
@@ -16,3 +16,6 @@ Description = Tool zum Erstellen und Öffnen von 7zip, zip, tar, rar und andrern
[Section.040a]
Description = Utilidad para crear y abrir 7zip, zip, tar, rar y otros archivos comprimidos.
+
+[Section.0422]
+Description = Утиліта для створення та відкриття 7zip, zip, tar, rar та інших архівних файлів.
diff --git a/base/applications/rapps/rapps/abiword.txt b/base/applications/rapps/rapps/abiword.txt
index bdba833d811..9ce5c9bb3c5 100644
--- a/base/applications/rapps/rapps/abiword.txt
+++ b/base/applications/rapps/rapps/abiword.txt
@@ -19,3 +19,6 @@ Description = Procesador de textos.
[Section.0415]
Description = Edytor tekstu.
+
+[Section.0422]
+Description = Текстовий процесор.
diff --git a/base/applications/rapps/rapps/abiword28x.txt b/base/applications/rapps/rapps/abiword28x.txt
new file mode 100644
index 00000000000..5a9b178efcf
--- /dev/null
+++ b/base/applications/rapps/rapps/abiword28x.txt
@@ -0,0 +1,24 @@
+; UTF-8
+
+[Section]
+Name = AbiWord
+Version = 2.8.6
+Licence = GPL
+Description = Word processor.
+Size = 7.9MB
+Category = 6
+URLSite = http://www.abisource.com/
+URLDownload = http://www.abisource.com/downloads/abiword/2.8.6/Windows/abiword-setup-2.8.6.exe
+CDPath = none
+
+[Section.0407]
+Description = Textverarbeitung.
+
+[Section.040a]
+Description = Procesador de textos.
+
+[Section.0415]
+Description = Edytor tekstu.
+
+[Section.0422]
+Description = Текстовий процесор.
diff --git a/base/applications/rapps/rapps/abyss.txt b/base/applications/rapps/rapps/abyss.txt
index 0369bf5ca89..49d505cf414 100644
--- a/base/applications/rapps/rapps/abyss.txt
+++ b/base/applications/rapps/rapps/abyss.txt
@@ -13,3 +13,6 @@ CDPath = none
[Section.0407]
Description = Abyss Web Server ermöglicht es Webseiten auf Ihrem Computer zu hosten. Er unterstützt sichere SSL/TLS Verbindungen (HTTPS) sowie eine Vielfalt an Web Technologien. Er kann ebenfalls PHP, Perl, Python, ASP, ASP.NET, und Ruby on Rails Web Anwendungen ausführen, welche von Datenbanken, wie MySQL, SQLite, MS SQL Server, MS Access, oder Oracle unterstützt werden können.
+
+[Section.0422]
+Description = Abyss Web Server дозволить вам утримувати веб-сайти на вашому комп'ютері. Від підтримує безпечні SSL/TLS з'єднання (HTTPS) та великий ряд веб-технологій. Він також запускає PHP, Perl, Python, ASP, ASP.NET, та Ruby on Rails веб-додатки, які можуть підтримуватись такими базами даних, як MySQL, SQLite, MS SQL Server, MS Access, чи Oracle.
diff --git a/base/applications/rapps/rapps/ac97forvirtualbox.txt b/base/applications/rapps/rapps/ac97forvirtualbox.txt
index 3fde45eb479..882d4b4b410 100644
--- a/base/applications/rapps/rapps/ac97forvirtualbox.txt
+++ b/base/applications/rapps/rapps/ac97forvirtualbox.txt
@@ -34,3 +34,9 @@ Name = Драйвер AC97 для VirtualBox
Licence = Не указано
Description = Разархивируйте содержимое в папку "ReactOS", затем дважды перезагрузите систему.
URLSite = Не указано
+
+[Section.0422]
+Name = Драйвер AC97 для VirtualBox
+Licence = Невідома
+Description = Разархівуйте вміст в теку "ReactOS" після чого двічі перезавантажте систему.
+URLSite = Не вказано
diff --git a/base/applications/rapps/rapps/audiograbber.txt b/base/applications/rapps/rapps/audiograbber.txt
index 9640b961ae8..69aeee9926b 100644
--- a/base/applications/rapps/rapps/audiograbber.txt
+++ b/base/applications/rapps/rapps/audiograbber.txt
@@ -19,3 +19,6 @@ Description = Un buen CD Ripper/ conversor de archivos de audio.
[Section.0415]
Description = Bardzo dobry CD Ripper/konwerter plików audio.
+
+[Section.0422]
+Description = Чудовий CD Ріппер/Конвертер аудіо файлів.
diff --git a/base/applications/rapps/rapps/comctl32ocx.txt b/base/applications/rapps/rapps/comctl32ocx.txt
new file mode 100644
index 00000000000..a678a338180
--- /dev/null
+++ b/base/applications/rapps/rapps/comctl32ocx.txt
@@ -0,0 +1,28 @@
+; UTF-8
+
+[Section]
+Name = Microsoft Visual Basic 6.0 Common Controls
+Version = 6.0
+Licence = Unknown
+Description = File needed by some applications.
+Size = 914kB
+Category = 14
+URLSite = http://www.microsoft.com/downloads/details.aspx?FamilyID=25437D98-51D0-41C1-BB14-64662F5F62FE&displaylang=en
+URLDownload = http://download.microsoft.com/download/3/a/5/3a5925ac-e779-4b1c-bb01-af67dc2f96fc/VisualBasic6-KB896559-v1-ENU.exe
+CDPath = none
+
+[Section.0407]
+Licence = Unbekannt
+Description = Datei wird von einigen Anwendungen benötigt.
+
+[Section.040a]
+Licence = Desconocida
+Description = X es necesario para varias aplicaciones.
+
+[Section.0415]
+Licence = Nieznana
+Description = X jest używana przez część aplikacji.
+
+[Section.0422]
+Licence = Невідома
+Description = Файл потрібен декотрим програмам.
diff --git a/base/applications/rapps/rapps/diablo2.txt b/base/applications/rapps/rapps/diablo2.txt
index cb985244cd2..09677af388a 100644
--- a/base/applications/rapps/rapps/diablo2.txt
+++ b/base/applications/rapps/rapps/diablo2.txt
@@ -19,3 +19,6 @@ Description = Diablo 2 Shareware. zeckensack's glide wrapper es necesario para s
[Section.0415]
Description = Diablo 2 Shareware. Do poprawnego działania wymagany jest zainstalowany zeckensacks glide wrapper.
+
+[Section.0422]
+Description = Diablo 2 Shareware. Для запуску потрібен zeckensack's glide wrapper.
diff --git a/base/applications/rapps/rapps/dosblaster.txt b/base/applications/rapps/rapps/dosblaster.txt
index 8a8f478f874..3974dda66aa 100644
--- a/base/applications/rapps/rapps/dosblaster.txt
+++ b/base/applications/rapps/rapps/dosblaster.txt
@@ -16,3 +16,6 @@ Description = DosBlaster ist eine Shell Extension, die es ermöglicht jede DOS A
[Section.040a]
Description = DosBlaster en una extensión Shell que permite abrir cualquier ejecutable DOS en DOSBox desde el botón derecho del ratón. Esta versión contiene DOSBox 0.70, pero puede ser actualizado facilmente instalando una nueva versión de DOSBox en la carpeta de DosBlaster.
+
+[Section.0422]
+Description = DosBlaster це розширення оболонки, яке дозволяє запустити будь-який виконавчий файл DOS в DOSBox через правий клік. Ця версія містить DOSBox 0.70, але може бути оновлена встановленням новішої версії DOSBox в теки DosBlaster.
diff --git a/base/applications/rapps/rapps/dosbox.txt b/base/applications/rapps/rapps/dosbox.txt
index 7a25f08dcb9..9c19faa6b25 100644
--- a/base/applications/rapps/rapps/dosbox.txt
+++ b/base/applications/rapps/rapps/dosbox.txt
@@ -19,3 +19,6 @@ Description = DOSBox es un emulador de DOS.
[Section.0415]
Description = DOSBox - emulator DOSa.
+
+[Section.0422]
+Description = DOSBox - емулятор DOSу.
diff --git a/base/applications/rapps/rapps/firefox2.txt b/base/applications/rapps/rapps/firefox2.txt
index e0b62661193..cc22a762b8c 100644
--- a/base/applications/rapps/rapps/firefox2.txt
+++ b/base/applications/rapps/rapps/firefox2.txt
@@ -25,3 +25,6 @@ Description = Najpopularniejsza i jedna z najlepszych darmowych przeglądarek in
[Section.0419]
Description = Один из самых популярных и лучших бесплатных браузеров.
+
+[Section.0422]
+Description = Найпопулярніший та один з кращих безплатних веб-браузерів.
diff --git a/base/applications/rapps/rapps/firefox3.txt b/base/applications/rapps/rapps/firefox3.txt
index 284c872da4d..f9978c34ba4 100644
--- a/base/applications/rapps/rapps/firefox3.txt
+++ b/base/applications/rapps/rapps/firefox3.txt
@@ -40,3 +40,9 @@ Description = Один из самых популярных и лучших бе
Size = 7.4M
URLSite = http://www.mozilla-europe.org/ru/
URLDownload = http://releases.mozilla.org/pub/mozilla.org/firefox/releases/3.0.19-real-real/win32/ru/Firefox%20Setup%203.0.19.exe
+
+[Section.0422]
+Description = Найпопулярніший та один з кращих безплатних веб-браузерів.
+Size = 7.3M
+URLSite = http://www.mozilla-europe.org/uk/
+URLDownload = http://releases.mozilla.org/pub/mozilla.org/firefox/releases/3.0.19-real-real/win32/uk/Firefox%20Setup%203.0.19.exe
diff --git a/base/applications/rapps/rapps/firefox36.txt b/base/applications/rapps/rapps/firefox36.txt
new file mode 100644
index 00000000000..1c6d932ecee
--- /dev/null
+++ b/base/applications/rapps/rapps/firefox36.txt
@@ -0,0 +1,48 @@
+; UTF-8
+
+[Section]
+Name = Mozilla Firefox 3.6
+Version = 3.6.3
+Licence = MPL/GPL/LGPL
+Description = The most popular and one of the best free Web Browsers out there.
+Size = 8.0M
+Category = 5
+URLSite = http://www.mozilla.com/en-US/
+URLDownload = http://releases.mozilla.org/pub/mozilla.org/firefox/releases/3.6.3/win32/en-US/Firefox%20Setup%203.6.3.exe
+CDPath = none
+
+[Section.0407]
+Description = Der populärste und einer der besten freien Webbrowser.
+Size = 7.8M
+URLSite = http://www.mozilla-europe.org/de/
+URLDownload = http://releases.mozilla.org/pub/mozilla.org/firefox/releases/3.6.3/win32/de/Firefox%20Setup%203.6.3.exe
+
+[Section.040a]
+Description = El más popular y uno de los mejores navegadores web gratuitos que hay.
+Size = 7.8M
+URLSite = http://www.mozilla-europe.org/es/
+URLDownload = http://releases.mozilla.org/pub/mozilla.org/firefox/releases/3.6.3/win32/es-ES/Firefox%20Setup%203.6.3.exe
+
+[Section.0414]
+Description = Mest populære og best også gratis nettleserene der ute.
+Size = 7.8M
+URLSite = http://www.mozilla-europe.org/no/
+URLDownload = http://releases.mozilla.org/pub/mozilla.org/firefox/releases/3.6.3/win32/nb-NO/Firefox%20Setup%203.6.3.exe
+
+[Section.0415]
+Description = Najpopularniejsza i jedna z najlepszych darmowych przeglądarek internetowych.
+Size = 8.6M
+URLSite = http://www.mozilla-europe.org/pl/
+URLDownload = http://releases.mozilla.org/pub/mozilla.org/firefox/releases/3.6.3/win32/pl/Firefox%20Setup%203.6.3.exe
+
+[Section.0419]
+Description = Один из самых популярных и лучших бесплатных браузеров.
+Size = 8.2M
+URLSite = http://www.mozilla-europe.org/ru/
+URLDownload = http://releases.mozilla.org/pub/mozilla.org/firefox/releases/3.6.3/win32/ru/Firefox%20Setup%203.6.3.exe
+
+[Section.0422]
+Description = Найпопулярніший та один з кращих безплатних веб-браузерів.
+Size = 8.2M
+URLSite = http://www.mozilla-europe.org/uk/
+URLDownload = http://releases.mozilla.org/pub/mozilla.org/firefox/releases/3.6.3/win32/uk/Firefox%20Setup%203.6.3.exe
diff --git a/base/applications/rapps/rapps/freebasic.txt b/base/applications/rapps/rapps/freebasic.txt
index fdd00f996a7..0463d68f427 100644
--- a/base/applications/rapps/rapps/freebasic.txt
+++ b/base/applications/rapps/rapps/freebasic.txt
@@ -19,3 +19,6 @@ Description = Compilador BASIC de código abierto. El lenguaje BASIC es compatib
[Section.0415]
Description = Otwarty kompilator BASIC, ze składnią kompatybilną z QBASIC.
+
+[Section.0422]
+Description = Відкритий компілятор BASIC. Синтаксис сумісний з QBASIC.
diff --git a/base/applications/rapps/rapps/glidewrapzbag.txt b/base/applications/rapps/rapps/glidewrapzbag.txt
index d474471c2ce..7870fbe4f98 100644
--- a/base/applications/rapps/rapps/glidewrapzbag.txt
+++ b/base/applications/rapps/rapps/glidewrapzbag.txt
@@ -19,3 +19,6 @@ Description = glidewrapper es necesario para ejecutar Diablo 2 en ReactOS.
[Section.0415]
Description = glidewrapper jest potrzebny do uruchomienia Diablo2 w ReactOS-ie.
+
+[Section.0422]
+Description = glidewrapper необхідний для запуску Diablo2 в ReactOS.
diff --git a/base/applications/rapps/rapps/irfanview.txt b/base/applications/rapps/rapps/irfanview.txt
index c392d1eea3e..760c3db69a4 100644
--- a/base/applications/rapps/rapps/irfanview.txt
+++ b/base/applications/rapps/rapps/irfanview.txt
@@ -22,3 +22,7 @@ Description = Visor para toda clase de archivos de imagen,audio y video.
[Section.0415]
Licence = Freeware (dla użytku domowego)
Description = Przeglądarka dla bardzo wielu typów obrazów, plików audio oraz wideo.
+
+[Section.0422]
+Licence = Freeware (для домашнього використання)
+Description = Переглядач для всіх видів графічних та аудіо/відео файлів.
diff --git a/base/applications/rapps/rapps/irfanviewplugins.txt b/base/applications/rapps/rapps/irfanviewplugins.txt
index fc7ab238b6e..eb9c8ffcef5 100644
--- a/base/applications/rapps/rapps/irfanviewplugins.txt
+++ b/base/applications/rapps/rapps/irfanviewplugins.txt
@@ -22,3 +22,7 @@ Description = Complementos adicionales para soportar más formatos.
[Section.0415]
Licence = Freeware (dla użytku domowego)
Description = Wtyczki otwierające dodatkowe typy plików w Irfanview.
+
+[Section.0422]
+Licence = Freeware (для домашнього використання)
+Description = Додаткові плагіни для підтримки більшої кількості файлових типів.
diff --git a/base/applications/rapps/rapps/kdewin.txt b/base/applications/rapps/rapps/kdewin.txt
new file mode 100644
index 00000000000..b12ebedb53f
--- /dev/null
+++ b/base/applications/rapps/rapps/kdewin.txt
@@ -0,0 +1,18 @@
+; UTF-8
+
+[Section]
+Name = K Desktop Environment
+Version = 0.9.6-5
+Licence = GPL
+Description = KDE for Windows.
+Size = 2.0MB
+Category = 15
+URLSite = http://www.winkde.org/
+URLDownload = http://www.winkde.org/pub/kde/ports/win32/installer/kdewin-installer-gui-0.9.6-5.exe
+CDPath = none
+
+[Section.0407]
+Description = KDE für Windows.
+
+[Section.0422]
+Description = KDE для Windows.
diff --git a/base/applications/rapps/rapps/lbreakout2.txt b/base/applications/rapps/rapps/lbreakout2.txt
index 403a3f9913a..1efbc13796d 100644
--- a/base/applications/rapps/rapps/lbreakout2.txt
+++ b/base/applications/rapps/rapps/lbreakout2.txt
@@ -19,3 +19,6 @@ Description = Clon de Breakout usando las librerias SDL.
[Section.0415]
Description = Klon Breakouta/Arkanoida napisany przy użyciu biblioteki SDL.
+
+[Section.0422]
+Description = Клон Breakouta/Arkanoida, що використовує бібліотеки SDL.
diff --git a/base/applications/rapps/rapps/lgeneral.txt b/base/applications/rapps/rapps/lgeneral.txt
index 48bda818632..905fb5e0039 100644
--- a/base/applications/rapps/rapps/lgeneral.txt
+++ b/base/applications/rapps/rapps/lgeneral.txt
@@ -19,3 +19,6 @@ Description = Clon de Panzer General usando las librerias SDL.
[Section.0415]
Description = Klon gry Panzer General napisany przy użyciu biblioteki SDL.
+
+[Section.0422]
+Description = Клон гри Panzer General, що використовує бібліотеки SDL.
diff --git a/base/applications/rapps/rapps/lmarbles.txt b/base/applications/rapps/rapps/lmarbles.txt
index 45a5fb5f770..7bd0b3f9498 100644
--- a/base/applications/rapps/rapps/lmarbles.txt
+++ b/base/applications/rapps/rapps/lmarbles.txt
@@ -19,3 +19,6 @@ Description = Clon de Atomix usando las librerias SDL.
[Section.0415]
Description = Klon gry Atomix, używający biblioteki SDL.
+
+[Section.0422]
+Description = Клон гри Atomix, що використовує бібліотеки SDL.
diff --git a/base/applications/rapps/rapps/mfc40.txt b/base/applications/rapps/rapps/mfc40.txt
index f361ccf1532..c0d85391605 100644
--- a/base/applications/rapps/rapps/mfc40.txt
+++ b/base/applications/rapps/rapps/mfc40.txt
@@ -25,3 +25,8 @@ Description = MFC 4 es necesario para varias aplicaciones.
Name = Przeglądarka OLE oraz MFC (Microsoft Foundation Classes) wersja 4
Licence = Nieznana
Description = Biblioteka MFC 4 jest używana przez część aplikacji.
+
+[Section.0422]
+Name = Переглядач OLE та MFC (Microsoft Foundation Classes) версія 4
+Licence = Невідома
+Description = Бібліотека MFC 4 необхідна декотрим програмам.
diff --git a/base/applications/rapps/rapps/mingw.txt b/base/applications/rapps/rapps/mingw.txt
index 89a70b229fe..b351b9168b3 100644
--- a/base/applications/rapps/rapps/mingw.txt
+++ b/base/applications/rapps/rapps/mingw.txt
@@ -19,3 +19,6 @@ Description = Es una cadena de herramientas GNU con GCC, GDB, GNU make, etc.
[Section.0415]
Description = Kompilator GCC dla platformy Windows wraz z dodatkowymi narzędziami (GDB, make, itd.).
+
+[Section.0422]
+Description = Компілятор GCC для платформи Windows з додатковими інструментами GDB, GNU make, та ін.
diff --git a/base/applications/rapps/rapps/mirandaim.txt b/base/applications/rapps/rapps/mirandaim.txt
index 5845bf7eb97..16a19764fe9 100644
--- a/base/applications/rapps/rapps/mirandaim.txt
+++ b/base/applications/rapps/rapps/mirandaim.txt
@@ -2,13 +2,13 @@
[Section]
Name = Miranda IM
-Version = 0.8.24
+Version = 0.8.26
Licence = GPL
Description = Open source multiprotocol instant messaging application - May not work completely.
-Size = 1.7MB
+Size = 1.8MB
Category = 5
URLSite = http://www.miranda-im.org/
-URLDownload = http://miranda.googlecode.com/files/miranda-im-v0.8.24-unicode.exe
+URLDownload = http://miranda.googlecode.com/files/miranda-im-v0.8.26-unicode.exe
CDPath = none
[Section.0407]
@@ -19,3 +19,6 @@ Description = Aplicación de mensajería instantánea multiprotocolo de código
[Section.0415]
Description = Otwarty komunikator internetowy, obsługujący wiele różnych protokołów (m.in. GG, Tlen, Jabber, ICQ, IRC) - może nie działać prawidłowo.
+
+[Section.0422]
+Description = Відкрита мультипротокольна програма миттєвих повідомлень - може не працювати повністю.
diff --git a/base/applications/rapps/rapps/mirc.txt b/base/applications/rapps/rapps/mirc.txt
index 2290ea2c59e..16d84e21658 100644
--- a/base/applications/rapps/rapps/mirc.txt
+++ b/base/applications/rapps/rapps/mirc.txt
@@ -19,3 +19,6 @@ Description = El más popular cliente para Internet Relay Chat (IRC).
[Section.0415]
Description = Najpopularniejszy klient IRC (Internet Relay Chat).
+
+[Section.0422]
+Description = Найпопулярніший клієнт IRC (Internet Relay Chat).
diff --git a/base/applications/rapps/rapps/mono2.txt b/base/applications/rapps/rapps/mono2.txt
new file mode 100644
index 00000000000..8a3427b4be9
--- /dev/null
+++ b/base/applications/rapps/rapps/mono2.txt
@@ -0,0 +1,15 @@
+; UTF-8
+
+[Section]
+Name = Mono .net Development Framework
+Version = 2.6.4
+Licence = Unknown
+Description = Open Source .net Framework.
+Size = 71MB
+Category = 14
+URLSite = http://www.mono-project.com/Main_Page
+URLDownload = http://ftp.novell.com/pub/mono/archive/2.6.4/windows-installer/3/mono-2.6.4-gtksharp-2.12.10-win32-3.exe
+CDPath = none
+
+[Section.0422]
+Description = Відкритий .net Фреймворк.
diff --git a/base/applications/rapps/rapps/mpc.txt b/base/applications/rapps/rapps/mpc.txt
new file mode 100644
index 00000000000..6772930e6b8
--- /dev/null
+++ b/base/applications/rapps/rapps/mpc.txt
@@ -0,0 +1,24 @@
+; UTF-8
+
+[Section]
+Name = Media Player Classic Home Cinema
+Version = 1.3.1249
+Licence = GPL
+Description = A media player.
+Size = 3.0MB
+Category = 1
+URLSite = http://mpc-hc.sourceforge.net/
+URLDownload = http://mesh.dl.sourceforge.net/project/mpc-hc/MPC%20HomeCinema%20-%20Win32/MPC-HC%20v1.3.1249.0_32%20bits/MPC-HomeCinema.1.3.1249.0.%28x86%29.exe
+CDPath = none
+
+[Section.0407]
+Description = Ein Medienplayer.
+
+[Section.040a]
+Description = Reproductor multimedia.
+
+[Section.0419]
+Description = Мультимедийный проигрыватель.
+
+[Section.0422]
+Description = Мультимедійний програвач.
diff --git a/base/applications/rapps/rapps/msxml3.txt b/base/applications/rapps/rapps/msxml3.txt
index 2a5360fa4ff..4147a2ca074 100644
--- a/base/applications/rapps/rapps/msxml3.txt
+++ b/base/applications/rapps/rapps/msxml3.txt
@@ -22,3 +22,7 @@ Description = MSXML3 para varios instaladores MSI.
[Section.0415]
Licence = Nieznana
Description = Niektóre spośród plików instalacyjnych MSI potrzebują parsera MSXML3.
+
+[Section.0422]
+Licence = Невідома
+Description = MSXML3 необхідна для декотрих MSI інсталяторів.
diff --git a/base/applications/rapps/rapps/net11.txt b/base/applications/rapps/rapps/net11.txt
new file mode 100644
index 00000000000..f6d4ca63f27
--- /dev/null
+++ b/base/applications/rapps/rapps/net11.txt
@@ -0,0 +1,12 @@
+; UTF-8
+
+[Section]
+Name = Microsoft .NET Framework Version 1.1 Redistributable Package
+Version = 1.1
+Licence = Unknown
+Description = Microsoft .NET Framework Version 1.1 Redistributable Package.
+Size = 23.1MB
+Category = 14
+URLSite = http://www.microsoft.com/downloads/details.aspx?FamilyId=262D25E3-F589-4842-8157-034D1E7CF3A3
+URLDownload = http://download.microsoft.com/download/a/a/c/aac39226-8825-44ce-90e3-bf8203e74006/dotnetfx.exe
+CDPath = none
diff --git a/base/applications/rapps/rapps/net20.txt b/base/applications/rapps/rapps/net20.txt
new file mode 100644
index 00000000000..cb83683985c
--- /dev/null
+++ b/base/applications/rapps/rapps/net20.txt
@@ -0,0 +1,12 @@
+; UTF-8
+
+[Section]
+Name = Microsoft .NET Framework Version 2.0 Redistributable Package
+Version = 2.0
+Licence = Unknown
+Description = Microsoft .NET Framework Version 2.0 Redistributable Package.
+Size = 22.4MB
+Category = 14
+URLSite = http://www.microsoft.com/downloads/details.aspx?FamilyID=0856eacb-4362-4b0d-8edd-aab15c5e04f5
+URLDownload = http://download.microsoft.com/download/5/6/7/567758a3-759e-473e-bf8f-52154438565a/dotnetfx.exe
+CDPath = none
diff --git a/base/applications/rapps/rapps/net20sp2.txt b/base/applications/rapps/rapps/net20sp2.txt
new file mode 100644
index 00000000000..65c98858d43
--- /dev/null
+++ b/base/applications/rapps/rapps/net20sp2.txt
@@ -0,0 +1,12 @@
+; UTF-8
+
+[Section]
+Name = Microsoft .NET Framework Version 2.0 Service Pack 2
+Version = 2.0SP2
+Licence = Unknown
+Description = Microsoft .NET Framework Version 2.0 Service Pack 2
+Size = 23.8MB
+Category = 14
+URLSite = http://www.microsoft.com/downloads/details.aspx?familyid=5B2C0358-915B-4EB5-9B1D-10E506DA9D0F
+URLDownload = http://download.microsoft.com/download/c/6/e/c6e88215-0178-4c6c-b5f3-158ff77b1f38/NetFx20SP2_x86.exe
+CDPath = none
diff --git a/base/applications/rapps/rapps/offbyone.txt b/base/applications/rapps/rapps/offbyone.txt
index 3ded431ded0..16ce1967277 100644
--- a/base/applications/rapps/rapps/offbyone.txt
+++ b/base/applications/rapps/rapps/offbyone.txt
@@ -19,3 +19,6 @@ Description = Es un pequeño y rápido navegador web con completo soporte HTML 3
[Section.0415]
Description = Bardzo mała i szybka przeglądarka internetowa z pełną obsługą HTML 3.2.
+
+[Section.0422]
+Description = Дуже малий та швидкий веб-браузер з повною підтримкою HTML 3.2.
diff --git a/base/applications/rapps/rapps/openoffice2.4.txt b/base/applications/rapps/rapps/openoffice2.4.txt
index d68f92e3418..89434276526 100644
--- a/base/applications/rapps/rapps/openoffice2.4.txt
+++ b/base/applications/rapps/rapps/openoffice2.4.txt
@@ -28,3 +28,9 @@ URLSite = http://pl.openoffice.org/
Description = Otwarty pakiet biurowy.
URLDownload = ftp://archive.services.openoffice.org/pub/openoffice-archive/localized/pl/2.4.2/OOo_2.4.2_Win32Intel_install_pl.exe
Size = 113.9M
+
+[Section.0422]
+URLSite = http://ua.openoffice.org/
+Description = Відкритий офісний пакет.
+URLDownload = ftp://archive.services.openoffice.org/pub/openoffice-archive/localized/ru/2.4.3/OOo_2.4.3_Win32Intel_install_ru.exe
+Size = 114.8M
diff --git a/base/applications/rapps/rapps/openoffice3.0.txt b/base/applications/rapps/rapps/openoffice3.0.txt
index 9ae02ef5d4e..2c06235c344 100644
--- a/base/applications/rapps/rapps/openoffice3.0.txt
+++ b/base/applications/rapps/rapps/openoffice3.0.txt
@@ -28,3 +28,9 @@ Description = Otwarty pakiet biurowy.
URLSite = http://pl.openoffice.org/
Size = 130.0MB
URLDownload = http://ftp3.gwdg.de/pub/openoffice/localized/pl/3.2.1/OOo_3.2.1_Win_x86_install_pl.exe
+
+[Section.0422]
+Description = Відкритий офісний пакет.
+URLSite = http://ua.openoffice.org/
+Size = 128.0MB
+URLDownload = http://ftp3.gwdg.de/pub/openoffice/localized/ru/3.2.1/OOo_3.2.1_Win_x86_install_ru.exe
diff --git a/base/applications/rapps/rapps/openttd.txt b/base/applications/rapps/rapps/openttd.txt
index b1f35d6c9f5..20b8ec52a02 100644
--- a/base/applications/rapps/rapps/openttd.txt
+++ b/base/applications/rapps/rapps/openttd.txt
@@ -2,13 +2,13 @@
[Section]
Name = OpenTTD
-Version = 1.0.1
+Version = 1.0.2
Licence = GPL v2
Description = Open Source clone of the "Transport Tycoon Deluxe" game engine. You need a copy of Transport Tycoon.
Size = 3.5MB
Category = 4
URLSite = http://www.openttd.org/
-URLDownload = http://binaries.openttd.org/releases/1.0.1/openttd-1.0.1-windows-win32.exe
+URLDownload = http://binaries.openttd.org/releases/1.0.2/openttd-1.0.2-windows-win32.exe
CDPath = none
[Section.0407]
@@ -19,3 +19,6 @@ Description = Clon del motor de juegos "Transport Tycoon Deluxe" de código abie
[Section.0415]
Description = Otwarty klon silnika gry "Transport Tycoon Deluxe". Do poprawnego działania potrzebna jest kopia gry Transport Tycoon.
+
+[Section.0422]
+Description = Відкритий клон двигуна гри "Transport Tycoon Deluxe". Вам потрібна копія гри Transport Tycoon.
diff --git a/base/applications/rapps/rapps/opera.txt b/base/applications/rapps/rapps/opera.txt
index 045e7e0f322..94ab020b263 100644
--- a/base/applications/rapps/rapps/opera.txt
+++ b/base/applications/rapps/rapps/opera.txt
@@ -2,13 +2,13 @@
[Section]
Name = Opera
-Version = 10.53
+Version = 10.54
Licence = Freeware
Description = The popular Opera Browser with many advanced features and including a Mail and BitTorrent client.
-Size = 12.4M
+Size = 12.5M
Category = 5
URLSite = http://www.opera.com/
-URLDownload = http://get4.opera.com/pub/opera/win/1053/int/Opera_1053_int_Setup.exe
+URLDownload = http://get4.opera.com/pub/opera/win/1054/int/Opera_1054_int_Setup.exe
CDPath = none
[Section.0407]
@@ -22,3 +22,6 @@ Description = Popularna przeglądarka internetowa z wieloma zaawansowanymi funkc
[Section.0419]
Description = Популярный браузер со многими дополнительными возможностями, включающий клиентов почты и BitTorrent.
+
+[Section.0422]
+Description = Популярний браузер з багатьма додатковими можливостями, який включає в себе поштовий та BitTorrent клієнти.
diff --git a/base/applications/rapps/rapps/opera9.txt b/base/applications/rapps/rapps/opera9.txt
new file mode 100644
index 00000000000..72c275a95f4
--- /dev/null
+++ b/base/applications/rapps/rapps/opera9.txt
@@ -0,0 +1,27 @@
+; UTF-8
+
+[Section]
+Name = Opera
+Version = 9.64
+Licence = Freeware
+Description = The popular Opera Browser with many advanced features and including a Mail and BitTorrent client.
+Size = 7.2M
+Category = 5
+URLSite = http://www.opera.com/
+URLDownload = http://get4.opera.com/pub/opera/win/964/int/Opera_964_int_Setup.exe
+CDPath = none
+
+[Section.0407]
+Description = Der populäre Opera Browser mit vielen fortschrittlichen Eigenschaften, enthält einen Mail und BitTorrent Client.
+
+[Section.040a]
+Description = Popular navegador web con muchas características avanzadas e incluye un cliente de correo y BitTorrent.
+
+[Section.0415]
+Description = Popularna przeglądarka internetowa z wieloma zaawansowanymi funkcjami, zawierająca klientów: poczty oraz BitTorrent.
+
+[Section.0419]
+Description = Популярный браузер со многими дополнительными возможностями, включающий клиентов почты и BitTorrent.
+
+[Section.0422]
+Description = Популярний браузер з багатьма додатковими можливостями, який включає в себе поштовий та BitTorrent клієнти.
diff --git a/base/applications/rapps/rapps/putty.txt b/base/applications/rapps/rapps/putty.txt
index 5566db28e65..f920f3b2db3 100644
--- a/base/applications/rapps/rapps/putty.txt
+++ b/base/applications/rapps/rapps/putty.txt
@@ -19,3 +19,6 @@ Description = Un ciente SSH, Telnet, rlogin y TCP gratuito.
[Section.0415]
Description = Darmowy klient obsługujący protokoły SSH, Telnet, rlogin oraz bezpośrednie TCP.
+
+[Section.0422]
+Description = Безплатний SSH, Telnet, rlogin та raw TCP клієнт.
diff --git a/base/applications/rapps/rapps/python.txt b/base/applications/rapps/rapps/python.txt
new file mode 100644
index 00000000000..dfbb9c2720d
--- /dev/null
+++ b/base/applications/rapps/rapps/python.txt
@@ -0,0 +1,18 @@
+; UTF-8
+
+[Section]
+Name = Python
+Version = 2.6.5
+Licence = GPL/LGPL
+Description = A remarkably powerful dynamic programming language.
+Size = 14MB
+Category = 7
+URLSite = http://www.python.org/
+URLDownload = http://www.python.org/ftp/python/2.6.5/python-2.6.5.msi
+CDPath = none
+
+[Section.0407]
+Description = Eine sehr mächtige, dynamische Programmiersprache.
+
+[Section.0422]
+Description = Дуже потужна динамічна мова програмування.
diff --git a/base/applications/rapps/rapps/remood.txt b/base/applications/rapps/rapps/remood.txt
index 2f16295b78c..5362c91a50f 100644
--- a/base/applications/rapps/rapps/remood.txt
+++ b/base/applications/rapps/rapps/remood.txt
@@ -13,3 +13,6 @@ CDPath = none
[Section.0407]
Description = ReMooD ist ein Port des Doom Legacy Sources. Es versucht das klassische Legacy Erfahrung zusammen mit neuen Features und mehr Stabilitt zu bieten. Untersttzt werden Windows 98/98SE/ME/NT/2000/XP/2003/ Vista/2008/7/XP 64-bit/2003 64-bit/Vista 64-bit/2008 64-bit/7 64-bit; ReactOS 0.3.x und hher; und Linux (x86 und x86_64).
+
+[Section.0422]
+Description = ReMooD э Портом вихідних кодів Doom Legacy. Його метою є додати нові можливості та стабільність до досвіду класичного Legacy. Він підтримує Windows 98/98SE/ME/NT/2000/XP/2003/ Vista/2008/7/XP 64-bit/2003 64-bit/Vista 64-bit/2008 64-bit/7 64-bit; ReactOS 0.3.x та новіші; а також Linux (x86 та x86_64).
diff --git a/base/applications/rapps/rapps/rosbe.txt b/base/applications/rapps/rapps/rosbe.txt
index a019299b9d1..7f0f5469b9f 100644
--- a/base/applications/rapps/rapps/rosbe.txt
+++ b/base/applications/rapps/rapps/rosbe.txt
@@ -19,3 +19,6 @@ Description = Te permite compilar el código de ReactOS. Para más instrucciones
[Section.0415]
Description = Pozwala zbudować obraz płyty ReactOS ze źródeł. Więcej informacji na Wiki ReactOS.
+
+[Section.0422]
+Description = Дозволяє зібрати ReactOS з вихідних кодів. За детальною інформацією дивіться в ReactOS Вікі.
diff --git a/base/applications/rapps/rapps/rosbeamd64.txt b/base/applications/rapps/rapps/rosbeamd64.txt
index c68b47af04f..1c84f548256 100644
--- a/base/applications/rapps/rapps/rosbeamd64.txt
+++ b/base/applications/rapps/rapps/rosbeamd64.txt
@@ -19,3 +19,6 @@ Description = Te permite compilar el código de ReactOS AMD64. Para más instruc
[Section.0415]
Description = Pozwala zbudować obraz płyty ReactOS AMD64 ze źródeł. Więcej informacji na Wiki ReactOS.
+
+[Section.0422]
+Description = Дозволяє зібрати ReactOS AMD64 з вихідних кодів. За детальною інформацією дивіться в ReactOS Вікі.
diff --git a/base/applications/rapps/rapps/rosbearm.txt b/base/applications/rapps/rapps/rosbearm.txt
index 61596d78dee..aac3ae1e9b4 100644
--- a/base/applications/rapps/rapps/rosbearm.txt
+++ b/base/applications/rapps/rapps/rosbearm.txt
@@ -19,3 +19,6 @@ Description = Te permite compilar el código de ReactOS ARM. Para más instrucci
[Section.0415]
Description = Pozwala zbudować obraz płyty ReactOS ARM ze źródeł. Więcej informacji na Wiki ReactOS.
+
+[Section.0422]
+Description = Дозволяє зібрати ReactOS ARM з вихідних кодів. За детальною інформацією дивіться в ReactOS Вікі.
diff --git a/base/applications/rapps/rapps/sambatng.txt b/base/applications/rapps/rapps/sambatng.txt
index 6cf579a9372..37dae7f7fec 100644
--- a/base/applications/rapps/rapps/sambatng.txt
+++ b/base/applications/rapps/rapps/sambatng.txt
@@ -19,3 +19,6 @@ Description = Esta utilidad le permite acceder a sus carpetas e impresoras compa
[Section.0415]
Description = Narzędzie pozwalające na dostęp z poziomu ReactOSa do współdzielonych folderów/drukarek Windows.
+
+[Section.0422]
+Description = Цей інструмент дозволяє отримати доступ до спільних тек/принтерів Windows з ReactOSа.
diff --git a/base/applications/rapps/rapps/scite.txt b/base/applications/rapps/rapps/scite.txt
index 2da34b49e95..9d114556166 100644
--- a/base/applications/rapps/rapps/scite.txt
+++ b/base/applications/rapps/rapps/scite.txt
@@ -16,3 +16,6 @@ Description = SciTE ist ein SCIntilla basierter Text Editor. Ursprünglich wurde
[Section.040a]
Description = Editor de texto basado en SCIntilla. Originalmente creado para demostrar Scintilla, a crecido para ser un gran editor con capacidad para crear y ejecutar programas.
+
+[Section.0422]
+Description = Текстовий редактор на основі SCIntilla. Був зібраний як презентація Scintilla, але виріс до редактора загального користування з засобами збирання та запуску програм.
diff --git a/base/applications/rapps/rapps/scummvm.txt b/base/applications/rapps/rapps/scummvm.txt
index d64e53c3653..27747581a66 100644
--- a/base/applications/rapps/rapps/scummvm.txt
+++ b/base/applications/rapps/rapps/scummvm.txt
@@ -19,3 +19,6 @@ Description = Sam and Max, Day of the Tentacle en ReactOS.
[Section.0415]
Description = Program pozwalający uruchomić stare gry przygodowe (Sam and Max, Day of the Tentacle, Monkey Island) w ReactOS.
+
+[Section.0422]
+Description = Дозволить грати Sam and Max, Day of the Tentacle та інші класичні ігри в ReactOS.
diff --git a/base/applications/rapps/rapps/sdl_mixer.txt b/base/applications/rapps/rapps/sdl_mixer.txt
index c9ebfce2c04..e667274e497 100644
--- a/base/applications/rapps/rapps/sdl_mixer.txt
+++ b/base/applications/rapps/rapps/sdl_mixer.txt
@@ -19,3 +19,6 @@ Description = Necesario para ejecutar varios juegos de código abierto. Necesita
[Section.0415]
Description = Biblioteka wymagana przez niektóre gry (zwłaszcza te o otwartym źródle). Do jej rozpakowania potrzebny jest 7-Zip lub podobny program.
+
+[Section.0422]
+Description = Необхідний для роботи декотрих відкритих ігор. Вам потрібен 7-Zip або подібна утиліта щоб розпакувати його.
diff --git a/base/applications/rapps/rapps/sdl_runtime.txt b/base/applications/rapps/rapps/sdl_runtime.txt
index 919746363ec..e7d993b6423 100644
--- a/base/applications/rapps/rapps/sdl_runtime.txt
+++ b/base/applications/rapps/rapps/sdl_runtime.txt
@@ -22,3 +22,7 @@ Description = Necesario para ejecutar varios juegos de código abierto. Necesita
[Section.0415]
Name = Biblioteka uruchomieniowa Simple Direct Media Layer (SDL)
Description = Wymagana przez wiele gier (głównie o otwartym źródle). Do jej rozpakowania potrzebny jest program 7-Zip lub podobny.
+
+[Section.0415]
+Name = Бібліотека Simple Direct Media Layer (SDL)
+Description = Необхідна для роботи багатьох відкритих ігор. Вам потрібен 7-Zip або подібна утиліта щоб розпакувати її.
diff --git a/base/applications/rapps/rapps/seamonkey.txt b/base/applications/rapps/rapps/seamonkey.txt
index 55d3be87f2f..1c2951b9ce3 100644
--- a/base/applications/rapps/rapps/seamonkey.txt
+++ b/base/applications/rapps/rapps/seamonkey.txt
@@ -8,25 +8,30 @@ Description = Mozilla Suite is alive. This is the one and only Browser, Mail, Ch
Size = 10.1MB
Category = 5
URLSite = http://www.seamonkey-project.org/
-URLDownload = http://ftp.df.lth.se/mozilla/seamonkey/releases/2.0.4/win32/en-US/SeaMonkey%20Setup%202.0.4.exe
+URLDownload = http://mozilla.mirror.ac.za/seamonkey/releases/2.0.4/win32/en-US/SeaMonkey%20Setup%202.0.4.exe
CDPath = none
[Section.0407]
Description = Mozilla Suite lebt. Dies ist das einzige Browser-, Mail-, Chat- and Composerwerkzeug-Bundle welches Sie benötigen.
Size = 10.0MB
-URLDownload = http://ftp.df.lth.se/mozilla/seamonkey/releases/2.0.4/win32/de/SeaMonkey%20Setup%202.0.4.exe
+URLDownload = http://mozilla.mirror.ac.za/seamonkey/releases/2.0.4/win32/de/SeaMonkey%20Setup%202.0.4.exe
[Section.040a]
Description = La suite de Mozilla está viva. Es el primero y único navegador web, gestor de correo, lector de noticias, Chat y editor HTML que necesitarás.
Size = 10.0MB
-URLDownload = http://ftp.df.lth.se/mozilla/seamonkey/releases/2.0.4/win32/es-ES/SeaMonkey%20Setup%202.0.4.exe
+URLDownload = http://mozilla.mirror.ac.za/seamonkey/releases/2.0.4/win32/es-ES/SeaMonkey%20Setup%202.0.4.exe
[Section.0415]
Description = Pakiet Mozilla żyje. W zestawie: przeglądarka, klient poczty, IRC oraz Edytor HTML - wszystko, czego potrzebujesz.
Size = 10.8MB
-URLDownload = http://ftp.df.lth.se/mozilla/seamonkey/releases/2.0.4/win32/pl/SeaMonkey%20Setup%202.0.4.exe
+URLDownload = http://mozilla.mirror.ac.za/seamonkey/releases/2.0.4/win32/pl/SeaMonkey%20Setup%202.0.4.exe
[Section.0419]
Description = Продолжение Mozilla Suite. Включает браузер, почтовый клиент, IRC-клиент и HTML-редактор.
Size = 10.4MB
-URLDownload = http://ftp.df.lth.se/mozilla/seamonkey/releases/2.0.4/win32/ru/SeaMonkey%20Setup%202.0.4.exe
+URLDownload = http://mozilla.mirror.ac.za/seamonkey/releases/2.0.4/win32/ru/SeaMonkey%20Setup%202.0.4.exe
+
+[Section.0422]
+Description = Mozilla Suite повернувся. Пакет містить в собі браузер, поштовий клієнт, IRC-клієнт та HTML-редактор.
+Size = 10.4MB
+URLDownload = http://mozilla.mirror.ac.za/seamonkey/releases/2.0.4/win32/ru/SeaMonkey%20Setup%202.0.4.exe
diff --git a/base/applications/rapps/rapps/smplayer.txt b/base/applications/rapps/rapps/smplayer.txt
index a2e47d3acff..f8039ae57b6 100644
--- a/base/applications/rapps/rapps/smplayer.txt
+++ b/base/applications/rapps/rapps/smplayer.txt
@@ -21,3 +21,7 @@ Description = Interfaz gráfico para Mplayer (reproductor multimedia).
[Section.0415]
URLSite = http://smplayer.sourceforge.net/index.php?tr_lang=pl
Description = Graficzna nakładka na MPlayer, otwarty odtwarzacz filmów.
+
+[Section.0422]
+URLSite = http://smplayer.sourceforge.net/index.php?tr_lang=uk
+Description = Графічний інтерфейс для MPlayer (мультимедійний плеєр).
diff --git a/base/applications/rapps/rapps/steam.txt b/base/applications/rapps/rapps/steam.txt
new file mode 100644
index 00000000000..3caccc4e584
--- /dev/null
+++ b/base/applications/rapps/rapps/steam.txt
@@ -0,0 +1,18 @@
+; UTF-8
+
+[Section]
+Name = STEAM
+Version = 1.0
+Licence = Freeware
+Description = The STEAM Gaming platform used by many games these days.
+Size = 1.5MB
+Category = 4
+URLSite = http://steampowered.com/
+URLDownload = http://storefront.steampowered.com/download/SteamInstall.msi
+CDPath = none
+
+[Section.0407]
+Description = Die STEAM Spieleplattform, die von viele Spielen verwendet wird.
+
+[Section.0422]
+Description = Ігрова платформа, що використовується багатьма іграми.
diff --git a/base/applications/rapps/rapps/tahoma.txt b/base/applications/rapps/rapps/tahoma.txt
new file mode 100644
index 00000000000..b5c87a0d3fe
--- /dev/null
+++ b/base/applications/rapps/rapps/tahoma.txt
@@ -0,0 +1,20 @@
+; UTF-8
+
+[Section]
+Name = Microsoft Tahoma Font
+Version = 1.0
+Licence = Unknown
+Description = Tahoma Font pack needed by some apps (Steam).
+Size = 305kB
+Category = 14
+URLSite = http://support.microsoft.com/
+URLDownload = http://download.microsoft.com/download/office97pro/fonts/1/w95/en-us/tahoma32.exe
+CDPath = none
+
+[Section.0407]
+Licence = Unbekannt
+Description = Tahoma Font pack, der von einigen Anwendungen benötigt wird (Steam).
+
+[Section.0422]
+Licence = Невідома
+Description = Пакет шрифтів Tahoma, що необхідні деяким програмам (Steam).
diff --git a/base/applications/rapps/rapps/thunderbird.txt b/base/applications/rapps/rapps/thunderbird.txt
index a9e837cd7e0..ea3cfa470c5 100644
--- a/base/applications/rapps/rapps/thunderbird.txt
+++ b/base/applications/rapps/rapps/thunderbird.txt
@@ -2,35 +2,41 @@
[Section]
Name = Mozilla Thunderbird
-Version = 3.0.4
+Version = 3.0.5
Licence = MPL/GPL/LGPL
Description = The most popular and one of the best free Mail Clients out there.
Size = 8.6M
Category = 5
URLSite = http://www.mozilla-europe.org/en/products/thunderbird/
-URLDownload = http://releases.mozilla.org/pub/mozilla.org/thunderbird/releases/3.0.4/win32/en-US/Thunderbird%20Setup%203.0.4.exe
+URLDownload = http://releases.mozilla.org/pub/mozilla.org/thunderbird/releases/3.0.5/win32/en-US/Thunderbird%20Setup%203.0.5.exe
CDPath = none
[Section.0407]
Description = Der populärste und einer der besten freien Mail-Clients.
Size = 8.5M
URLSite = http://www.mozilla-europe.org/de/products/thunderbird/
-URLDownload = http://releases.mozilla.org/pub/mozilla.org/thunderbird/releases/3.0.4/win32/de/Thunderbird%20Setup%203.0.4.exe
+URLDownload = http://releases.mozilla.org/pub/mozilla.org/thunderbird/releases/3.0.5/win32/de/Thunderbird%20Setup%203.0.5.exe
[Section.040a]
Description = El más popular y uno de los mejores clientes mail que hay.
Size = 8.4M
URLSite = http://www.mozilla-europe.org/es/products/thunderbird/
-URLDownload = http://releases.mozilla.org/pub/mozilla.org/thunderbird/releases/3.0.4/win32/es-ES/Thunderbird%20Setup%203.0.4.exe
+URLDownload = http://releases.mozilla.org/pub/mozilla.org/thunderbird/releases/3.0.5/win32/es-ES/Thunderbird%20Setup%203.0.5.exe
[Section.0415]
Description = Najpopularniejszy i jeden z najlepszych darmowych klientów poczty.
Size = 9.3M
URLSite = http://www.mozilla-europe.org/pl/products/thunderbird/
-URLDownload = http://releases.mozilla.org/pub/mozilla.org/thunderbird/releases/3.0.4/win32/pl/Thunderbird%20Setup%203.0.4.exe
+URLDownload = http://releases.mozilla.org/pub/mozilla.org/thunderbird/releases/3.0.5/win32/pl/Thunderbird%20Setup%203.0.5.exe
[Section.0419]
Description = Один из самых популярных и лучших бесплатных почтовых клиентов.
Size = 8.8M
URLSite = http://www.mozilla-europe.org/ru/products/thunderbird/
-URLDownload = http://releases.mozilla.org/pub/mozilla.org/thunderbird/releases/3.0.4/win32/ru/Thunderbird%20Setup%203.0.4.exe
+URLDownload = http://releases.mozilla.org/pub/mozilla.org/thunderbird/releases/3.0.5/win32/ru/Thunderbird%20Setup%203.0.5.exe
+
+[Section.0422]
+Description = Найпопулярніший та один з кращих поштових клієнтів.
+Size = 8.8M
+URLSite = http://www.mozillamessaging.com/uk/thunderbird/
+URLDownload = http://releases.mozilla.org/pub/mozilla.org/thunderbird/releases/3.0.5/win32/uk/Thunderbird%20Setup%203.0.5.exe
diff --git a/base/applications/rapps/rapps/tileworld.txt b/base/applications/rapps/rapps/tileworld.txt
index 8e7bb70f188..fe9cd2eb972 100644
--- a/base/applications/rapps/rapps/tileworld.txt
+++ b/base/applications/rapps/rapps/tileworld.txt
@@ -19,3 +19,6 @@ Description = Clon de Chip's Challenge originalmente creado para Atari Lynx. Inc
[Section.0415]
Description = Udany klon gry Chip's Challenge z Atari Lynx. Zawiera darmowy zestaw grafik CCLP2.
+
+[Section.0422]
+Description = Чудовий клон гри Chip's Challenge для Atari Lynx. Включено безплатний графічний пакет CCLP2, тому вам не потрібен оригінальний.
diff --git a/base/applications/rapps/rapps/tuxpaint.txt b/base/applications/rapps/rapps/tuxpaint.txt
index c3de5966beb..3931d501741 100644
--- a/base/applications/rapps/rapps/tuxpaint.txt
+++ b/base/applications/rapps/rapps/tuxpaint.txt
@@ -19,3 +19,6 @@ Description = Editor gráfico de imágenes pensado para niños de código abiert
[Section.0415]
Description = Otwarty program graficzny przeznaczony głównie dla dzieci.
+
+[Section.0422]
+Description = Відкритий графічний редактор для малих дітей.
diff --git a/base/applications/rapps/rapps/ultravnc.txt b/base/applications/rapps/rapps/ultravnc.txt
index dcd365ec9a4..f00b1434902 100644
--- a/base/applications/rapps/rapps/ultravnc.txt
+++ b/base/applications/rapps/rapps/ultravnc.txt
@@ -13,3 +13,6 @@ CDPath = none
[Section.040a]
Description = Cliente/Servidor VNC de código abierto.
+
+[Section.0422]
+Description = Відкритий VNC клієнт/сервер.
diff --git a/base/applications/rapps/rapps/utorrent.txt b/base/applications/rapps/rapps/utorrent.txt
index f987811b5a8..8e721644c5e 100644
--- a/base/applications/rapps/rapps/utorrent.txt
+++ b/base/applications/rapps/rapps/utorrent.txt
@@ -27,3 +27,7 @@ Description = Mały i szybki klient BitTorrent.
[Section.0419]
Licence = Бесплатная для некоммерческого использования
Description = Маленький и быстрый клиент BitTorrent.
+
+[Section.0422]
+Licence = Безплатна для некомерційного використання
+Description = Маленький і швидкий клієнт BitTorrent.
diff --git a/base/applications/rapps/rapps/vb5run.txt b/base/applications/rapps/rapps/vb5run.txt
index 296fd7a12fd..b916ea4ed5a 100644
--- a/base/applications/rapps/rapps/vb5run.txt
+++ b/base/applications/rapps/rapps/vb5run.txt
@@ -22,3 +22,7 @@ Description = Librerias Visual Basic 5.
[Section.0415]
Licence = Nieznana
Description = Biblioteki uruchomieniowe Visual Basic 5.
+
+[Section.0422]
+Licence = Невідома
+Description = Бібліотеки Visual Basic 5.
diff --git a/base/applications/rapps/rapps/vb6run.txt b/base/applications/rapps/rapps/vb6run.txt
index fed333b5a20..521a7fc1ba3 100644
--- a/base/applications/rapps/rapps/vb6run.txt
+++ b/base/applications/rapps/rapps/vb6run.txt
@@ -8,7 +8,7 @@ Description = Visual Basic 6 Runtime.
Size = 1.0MB
Category = 14
URLSite = http://support.microsoft.com/kb/192461/
-URLDownload = http://download.microsoft.com/download/vb60pro/install/6/win98me/en-us/vbrun60.exe
+URLDownload = http://download.microsoft.com/download/5/a/d/5ad868a0-8ecd-4bb0-a882-fe53eb7ef348/VB6.0-KB290887-X86.exe
CDPath = none
[Section.0407]
@@ -22,3 +22,7 @@ Description = Librerias Visual Basic 6.
[Section.0415]
Licence = Nieznana
Description = Biblioteki uruchomieniowe Visual Basic 6.
+
+[Section.0422]
+Licence = Невідома
+Description = Бібліотеки Visual Basic 6.
diff --git a/base/applications/rapps/rapps/vc2005run.txt b/base/applications/rapps/rapps/vc2005run.txt
index c5ef0cae69b..aff6bffffe6 100644
--- a/base/applications/rapps/rapps/vc2005run.txt
+++ b/base/applications/rapps/rapps/vc2005run.txt
@@ -8,7 +8,7 @@ Description = Visual Studio 2005 Runtime.
Size = 2.6MB
Category = 14
URLSite = http://www.microsoft.com/Downloads/details.aspx?displaylang=en&FamilyID=32bc1bee-a3f9-4c13-9c99-220b62a191ee
-URLDownload = http://download.microsoft.com/download/d/3/4/d342efa6-3266-4157-a2ec-5174867be706/vcredist_x86.exe
+URLDownload = http://download.microsoft.com/download/6/B/B/6BB661D6-A8AE-4819-B79F-236472F6070C/vcredist_x86.exe
CDPath = none
[Section.0407]
@@ -22,3 +22,7 @@ Description = Librerias Visual Studio 2005.
[Section.0415]
Licence = Nieznana
Description = Biblioteki uruchomieniowe Visual Studio 2005.
+
+[Section.0422]
+Licence = Невідома
+Description = Бібліотеки Visual Studio 2005.
diff --git a/base/applications/rapps/rapps/vc2005sp1run.txt b/base/applications/rapps/rapps/vc2005sp1run.txt
index b32df0d5e02..4c809b28767 100644
--- a/base/applications/rapps/rapps/vc2005sp1run.txt
+++ b/base/applications/rapps/rapps/vc2005sp1run.txt
@@ -22,3 +22,7 @@ Description = Librerias Visual Studio 2005 SP1.
[Section.0415]
Licence = Nieznana
Description = Biblioteki uruchomieniowe Visual Studio 2005 SP1.
+
+[Section.0422]
+Licence = Невідома
+Description = Бібліотеки Visual Studio 2005 SP1.
diff --git a/base/applications/rapps/rapps/vc2008run.txt b/base/applications/rapps/rapps/vc2008run.txt
index bb36b6010db..2bdaeb5f40c 100644
--- a/base/applications/rapps/rapps/vc2008run.txt
+++ b/base/applications/rapps/rapps/vc2008run.txt
@@ -5,10 +5,10 @@ Name = Visual Studio 2008 Runtime
Version = 8.0
Licence = Unknown
Description = Visual Studio 2008 Runtime.
-Size = 1.7MB
+Size = 4.3MB
Category = 14
URLSite = http://www.microsoft.com/DOWNLOADS/details.aspx?FamilyID=9b2da534-3e03-4391-8a4d-074b9f2bc1bf&displaylang=en
-URLDownload = http://download.microsoft.com/download/1/1/1/1116b75a-9ec3-481a-a3c8-1777b5381140/vcredist_x86.exe
+URLDownload = http://download.microsoft.com/download/9/7/7/977B481A-7BA6-4E30-AC40-ED51EB2028F2/vcredist_x86.exe
CDPath = none
[Section.0407]
@@ -22,3 +22,7 @@ Description = Librerias Visual Studio 2008.
[Section.0415]
Licence = Nieznana
Description = Biblioteki uruchomieniowe Visual Studio 2008.
+
+[Section.0422]
+Licence = Невідома
+Description = Бібліотеки Visual Studio 2008.
diff --git a/base/applications/rapps/rapps/vc6run.txt b/base/applications/rapps/rapps/vc6run.txt
index a93058e2942..384428e33d6 100644
--- a/base/applications/rapps/rapps/vc6run.txt
+++ b/base/applications/rapps/rapps/vc6run.txt
@@ -22,3 +22,7 @@ Description = Librerias Visual Studio 2006.
[Section.0415]
Licence = Nieznana
Description = Biblioteki uruchomieniowe Visual Studio 6.
+
+[Section.0422]
+Licence = Невідома
+Description = Бібліотеки Visual Studio 6.
diff --git a/base/applications/rapps/rapps/vlc.txt b/base/applications/rapps/rapps/vlc.txt
index d3d11d2fb76..57db5d0aeed 100644
--- a/base/applications/rapps/rapps/vlc.txt
+++ b/base/applications/rapps/rapps/vlc.txt
@@ -2,13 +2,13 @@
[Section]
Name = VLC media player
-Version = 1.0.5
+Version = 1.1.0
Licence = GPL
Description = A media player.
-Size = 17.2MB
+Size = 18.6MB
Category = 1
URLSite = http://www.videolan.org/vlc/
-URLDownload = http://mirror.services.wisc.edu/mirrors/videolan/vlc/1.0.5/win32/vlc-1.0.5-win32.exe
+URLDownload = http://ignum.dl.sourceforge.net/project/vlc/1.1.0/win32/vlc-1.1.0-win32.exe
CDPath = none
[Section.0407]
@@ -19,3 +19,6 @@ Description = Reproductor multimedia.
[Section.0419]
Description = Мультимедийный проигрыватель.
+
+[Section.0422]
+Description = Мультимедійний програвач.
diff --git a/base/applications/rapps/rapps/winboard.txt b/base/applications/rapps/rapps/winboard.txt
index bc8c6044390..b5486a23c40 100644
--- a/base/applications/rapps/rapps/winboard.txt
+++ b/base/applications/rapps/rapps/winboard.txt
@@ -19,3 +19,6 @@ Description = Tablero de ajedrez para Windows/ReactOS que puede ser utilizado co
[Section.0415]
Description = Graficzna szachownica dla systemu Windows/ReactOS, która może służyć jako graficzna nakładka dla GNU Chess, Crafty, lub innych programów szachowych(w tym internetowych serwerów szachowych) lub szachów korespondencyjnych.
+
+[Section.0422]
+Description = Графічна шахматна дошка для Windows/ReactOS, що може слугувати графічним інтерфейсом для GNU Chess, Crafty, та інших шахматних двигунів, для серверів інтернет-шахмат та для шахматної переписки по е-мейл.
diff --git a/base/applications/rapps/rapps/wme9.txt b/base/applications/rapps/rapps/wme9.txt
new file mode 100644
index 00000000000..842568e6f72
--- /dev/null
+++ b/base/applications/rapps/rapps/wme9.txt
@@ -0,0 +1,24 @@
+; UTF-8
+
+[Section]
+Name = Windows Media Encoder 9
+Version = 9.0
+Licence = Unknown
+Description = Windows Media Encoder 9
+Size = 9.5MB
+Category = 14
+URLSite = http://www.microsoft.com/downloads/details.aspx?FamilyID=5691ba02-e496-465a-bba9-b2f1182cdf24
+URLDownload = http://download.microsoft.com/download/8/1/f/81f9402f-efdd-439d-b2a4-089563199d47/WMEncoder.exe
+CDPath = none
+
+[Section.0407]
+Licence = Unbekannt
+
+[Section.040a]
+Licence = Desconocida
+
+[Section.0415]
+Licence = Nieznana
+
+[Section.0422]
+Licence = Невідома
diff --git a/baseaddress.rbuild b/baseaddress.rbuild
index 58a65efc7bc..c0bc87155d1 100644
--- a/baseaddress.rbuild
+++ b/baseaddress.rbuild
@@ -27,7 +27,7 @@
-
+
@@ -133,6 +133,7 @@
+
@@ -188,7 +189,7 @@
-
+
diff --git a/boot/bootdata/packages/reactos.dff b/boot/bootdata/packages/reactos.dff
index 4a1c4c3f6a4..7da30c27b68 100644
--- a/boot/bootdata/packages/reactos.dff
+++ b/boot/bootdata/packages/reactos.dff
@@ -365,6 +365,7 @@ dll\win32\msxml3\msxml3.dll 1
dll\win32\nddeapi\nddeapi.dll 1
dll\win32\netapi32\netapi32.dll 1
dll\win32\netcfgx\netcfgx.dll 1
+dll\win32\netevent\netevent.dll 1
dll\win32\netid\netid.dll 1
dll\win32\netshell\netshell.dll 1
dll\win32\newdev\newdev.dll 1
diff --git a/dll/3rdparty/mesa32/mesa32.rbuild b/dll/3rdparty/mesa32/mesa32.rbuild
index d160a8df692..c13d8eeaef4 100644
--- a/dll/3rdparty/mesa32/mesa32.rbuild
+++ b/dll/3rdparty/mesa32/mesa32.rbuild
@@ -32,21 +32,25 @@
src/shader/slang/OSDependent/Linux
src/shader/slang/OGLCompilersDLL
+
+
+ driverfuncs.c
+
+
+
+ wmesa.c
+ wgl.c
+
+
+ icd.c
+
+
+
glapi_getproc.c
glapi.c
glthread.c
-
- m_debug_clip.c
- m_debug_norm.c
- m_debug_xform.c
- m_eval.c
- m_matrix.c
- m_translate.c
- m_vector.c
- m_xform.c
-
accum.c
api_arrayelt.c
@@ -104,6 +108,9 @@
readpix.c
renderbuffer.c
scissor.c
+ shaders.c
+ state.c
+ stencil.c
texcompress.c
texcompress_fxt1.c
texcompress_s3tc.c
@@ -118,6 +125,17 @@
texstate.c
texstore.c
varray.c
+ vtxfmt.c
+
+
+ m_debug_clip.c
+ m_debug_norm.c
+ m_debug_xform.c
+ m_eval.c
+ m_matrix.c
+ m_translate.c
+ m_vector.c
+ m_xform.c
arbprogparse.c
@@ -137,6 +155,29 @@
prog_uniform.c
program.c
programopt.c
+ shader_api.c
+
+ slang_builtin.c
+ slang_codegen.c
+ slang_compile.c
+ slang_compile_function.c
+ slang_compile_operation.c
+ slang_compile_struct.c
+ slang_compile_variable.c
+ slang_emit.c
+ slang_ir.c
+ slang_label.c
+ slang_link.c
+ slang_log.c
+ slang_mem.c
+ slang_preprocess.c
+ slang_print.c
+ slang_simplify.c
+ slang_storage.c
+ slang_typeinfo.c
+ slang_utility.c
+ slang_vartable.c
+
grammar_mesa.c
@@ -172,42 +213,10 @@
s_triangle.c
s_zoom.c
-
- shaders.c
-
-
- shader_api.c
-
- slang_builtin.c
- slang_codegen.c
- slang_compile.c
- slang_compile_function.c
- slang_compile_operation.c
- slang_compile_struct.c
- slang_compile_variable.c
- slang_emit.c
- slang_ir.c
- slang_label.c
- slang_link.c
- slang_log.c
- slang_mem.c
- slang_preprocess.c
- slang_print.c
- slang_simplify.c
- slang_storage.c
- slang_typeinfo.c
- slang_utility.c
- slang_vartable.c
-
-
ss_context.c
ss_triangle.c
-
- state.c
- stencil.c
-
t_context.c
t_draw.c
@@ -246,24 +255,6 @@
vbo_split_copy.c
vbo_split_inplace.c
-
- vtxfmt.c
-
-
-
- driverfuncs.c
-
-
-
- wmesa.c
- wgl.c
-
-
- icd.c
-
-
-
-
diff --git a/dll/win32/msafd/misc/dllmain.c b/dll/win32/msafd/misc/dllmain.c
index b0b1f317159..2e22136ec48 100644
--- a/dll/win32/msafd/misc/dllmain.c
+++ b/dll/win32/msafd/misc/dllmain.c
@@ -23,6 +23,7 @@ HANDLE GlobalHeap;
WSPUPCALLTABLE Upcalls;
LPWPUCOMPLETEOVERLAPPEDREQUEST lpWPUCompleteOverlappedRequest;
PSOCKET_INFORMATION SocketListHead = NULL;
+CRITICAL_SECTION SocketListLock;
LIST_ENTRY SockHelpersListHead = { NULL, NULL };
ULONG SockAsyncThreadRefCount;
HANDLE SockAsyncHelperAfdHandle;
@@ -280,8 +281,10 @@ WSPSocket(int AddressFamily,
NULL);
/* Save in Process Sockets List */
+ EnterCriticalSection(&SocketListLock);
Socket->NextSocket = SocketListHead;
SocketListHead = Socket;
+ LeaveCriticalSection(&SocketListLock);
/* Create the Socket Context */
CreateContext(Socket);
@@ -556,6 +559,7 @@ WSPCloseSocket(IN SOCKET Handle,
NtClose(Socket->TdiConnectionHandle);
Socket->TdiConnectionHandle = NULL;
+ EnterCriticalSection(&SocketListLock);
if (SocketListHead == Socket)
{
SocketListHead = SocketListHead->NextSocket;
@@ -574,6 +578,7 @@ WSPCloseSocket(IN SOCKET Handle,
CurrentSocket = CurrentSocket->NextSocket;
}
}
+ LeaveCriticalSection(&SocketListLock);
HeapFree(GlobalHeap, 0, Socket);
@@ -2314,15 +2319,22 @@ GetSocketStructure(SOCKET Handle)
{
PSOCKET_INFORMATION CurrentSocket;
+ EnterCriticalSection(&SocketListLock);
+
CurrentSocket = SocketListHead;
while (CurrentSocket)
{
if (CurrentSocket->Handle == Handle)
+ {
+ LeaveCriticalSection(&SocketListLock);
return CurrentSocket;
+ }
CurrentSocket = CurrentSocket->NextSocket;
}
+ LeaveCriticalSection(&SocketListLock);
+
return NULL;
}
@@ -2841,6 +2853,9 @@ DllMain(HANDLE hInstDll,
/* Heap to use when allocating */
GlobalHeap = GetProcessHeap();
+ /* Initialize the lock that protects our socket list */
+ InitializeCriticalSection(&SocketListLock);
+
AFD_DbgPrint(MAX_TRACE, ("MSAFD.DLL has been loaded\n"));
break;
@@ -2852,6 +2867,10 @@ DllMain(HANDLE hInstDll,
break;
case DLL_PROCESS_DETACH:
+
+ /* Delete the socket list lock */
+ DeleteCriticalSection(&SocketListLock);
+
break;
}
diff --git a/dll/win32/msvcrt/msvcrt.def b/dll/win32/msvcrt/msvcrt.def
deleted file mode 100644
index 9fdd97ad02b..00000000000
--- a/dll/win32/msvcrt/msvcrt.def
+++ /dev/null
@@ -1,861 +0,0 @@
-;
-; ReactOS MSVCRT Library
-;
-LIBRARY msvcrt.dll
-
-EXPORTS
- $I10_OUTPUT=MSVCRT_I10_OUTPUT @57
- ??0__non_rtti_object@@QAE@ABV0@@Z=__thiscall_MSVCRT___non_rtti_object_copy_ctor @1
- ??0__non_rtti_object@@QAE@PBD@Z=__thiscall_MSVCRT___non_rtti_object_ctor @2
-; ??0bad_cast@@AAE@PBQBD@Z @3
- ??0bad_cast@@QAE@ABQBD@Z=__thiscall_MSVCRT_bad_cast_ctor @4
- ??0bad_cast@@QAE@ABV0@@Z=__thiscall_MSVCRT_bad_cast_copy_ctor @5
-; ??0bad_cast@@QAE@PBD@Z @6
- ??0bad_typeid@@QAE@ABV0@@Z=__thiscall_MSVCRT_bad_typeid_copy_ctor @7
- ??0bad_typeid@@QAE@PBD@Z=__thiscall_MSVCRT_bad_typeid_ctor @8
- ??0exception@@QAE@ABQBD@Z=__thiscall_MSVCRT_exception_ctor @9
-; ??0exception@@QAE@ABQBDH@Z @10
- ??0exception@@QAE@ABV0@@Z=__thiscall_MSVCRT_exception_copy_ctor @11
- ??0exception@@QAE@XZ=__thiscall_MSVCRT_exception_default_ctor @12
- ??1__non_rtti_object@@UAE@XZ=__thiscall_MSVCRT___non_rtti_object_dtor @13
- ??1bad_cast@@UAE@XZ=__thiscall_MSVCRT_bad_cast_dtor @14
- ??1bad_typeid@@UAE@XZ=__thiscall_MSVCRT_bad_typeid_dtor @15
- ??1exception@@UAE@XZ=__thiscall_MSVCRT_exception_dtor @16
- ??1type_info@@UAE@XZ=__thiscall_MSVCRT_type_info_dtor @17
- ??2@YAPAXI@Z=MSVCRT_operator_new @18
- ??3@YAXPAX@Z=MSVCRT_operator_delete @19
- ??4__non_rtti_object@@QAEAAV0@ABV0@@Z=__thiscall_MSVCRT___non_rtti_object_opequals @20
- ??4bad_cast@@QAEAAV0@ABV0@@Z=__thiscall_MSVCRT_bad_cast_opequals @21
- ??4bad_typeid@@QAEAAV0@ABV0@@Z=__thiscall_MSVCRT_bad_typeid_opequals @22
- ??4exception@@QAEAAV0@ABV0@@Z=__thiscall_MSVCRT_exception_opequals @23
- ??8type_info@@QBEHABV0@@Z=__thiscall_MSVCRT_type_info_opequals_equals @24
- ??9type_info@@QBEHABV0@@Z=__thiscall_MSVCRT_type_info_opnot_equals @25
- ??_7__non_rtti_object@@6B@=MSVCRT___non_rtti_object_vtable@@6B@ @26 DATA
- ??_7bad_cast@@6B@=MSVCRT_bad_cast_vtable @27 DATA
- ??_7bad_typeid@@6B@=MSVCRT_bad_typeid_vtable @28 DATA
- ??_7exception@@6B@=MSVCRT_exception_vtable @29 DATA
- ??_E__non_rtti_object@@UAEPAXI@Z=__thiscall_MSVCRT___non_rtti_object_vector_dtor @30
- ??_Ebad_cast@@UAEPAXI@Z=__thiscall_MSVCRT_bad_cast_vector_dtor @31
- ??_Ebad_typeid@@UAEPAXI@Z=__thiscall_MSVCRT_bad_typeid_vector_dtor @32
- ??_Eexception@@UAEPAXI@Z=__thiscall_MSVCRT_exception_vector_dtor @33
-; ??_Fbad_cast@@QAEXXZ @34
-; ??_Fbad_typeid@@QAEXXZ @35
- ??_G__non_rtti_object@@UAEPAXI@Z=__thiscall_MSVCRT___non_rtti_object_scalar_dtor @36
- ??_Gbad_cast@@UAEPAXI@Z=__thiscall_MSVCRT_bad_cast_scalar_dtor @37
- ??_Gbad_typeid@@UAEPAXI@Z=__thiscall_MSVCRT_bad_typeid_scalar_dtor @38
- ??_Gexception@@UAEPAXI@Z=__thiscall_MSVCRT_exception_scalar_dtor @39
- ??_U@YAPAXI@Z=MSVCRT_operator_new @40
- ??_V@YAXPAX@Z=MSVCRT_operator_delete @41
- ?_query_new_handler@@YAP6AHI@ZXZ=MSVCRT__query_new_handler @43
- ?_query_new_mode@@YAHXZ=MSVCRT__query_new_mode @44
- ?_set_new_handler@@YAP6AHI@ZP6AHI@Z@Z=MSVCRT__set_new_handler @45
- ?_set_new_mode@@YAHH@Z=MSVCRT__set_new_mode @46
- ?_set_se_translator@@YAP6AXIPAU_EXCEPTION_POINTERS@@@ZP6AXI0@Z@Z=MSVCRT__set_se_translator @47
- ?before@type_info@@QBEHABV1@@Z=__thiscall_MSVCRT_type_info_before @48
- ?name@type_info@@QBEPBDXZ=__thiscall_MSVCRT_type_info_name @49
- ?raw_name@type_info@@QBEPBDXZ=__thiscall_MSVCRT_type_info_raw_name @50
- ?set_new_handler@@YAP6AXXZP6AXXZ@Z=MSVCRT__set_new_handler @51
- ?set_terminate@@YAP6AXXZP6AXXZ@Z=MSVCRT_set_terminate @52
- ?set_unexpected@@YAP6AXXZP6AXXZ@Z=MSVCRT_set_unexpected @53
- ?terminate@@YAXXZ=MSVCRT_terminate @54
- ?unexpected@@YAXXZ=MSVCRT_unexpected @55
- ?what@exception@@UBEPBDXZ=__thiscall_MSVCRT_what_exception @56
- _CIacos @58
- _CIasin @59
- _CIatan @60
- _CIatan2 @61
- _CIcos @62
- _CIcosh @63
- _CIexp @64
- _CIfmod @65
- _CIlog @66
- _CIlog10 @67
- _CIpow @68
- _CIsin @69
- _CIsinh @70
- _CIsqrt @71
- _CItan @72
- _CItanh @73
- _CxxThrowException @74
- _EH_prolog @75
- _Getdays @76
- _Getmonths @77
- _Gettnames @78
- _HUGE @79 DATA
- _Strftime @80
- _XcptFilter @81
- __CppXcptFilter @82
-; __CxxCallUnwindDtor @83
-; __CxxCallUnwindVecDtor @84
- __CxxDetectRethrow @85
-; __CxxExceptionFilter @86
- __CxxFrameHandler @87
-; __CxxFrameHandler2 @88
- __CxxLongjmpUnwind @89
- __CxxQueryExceptionSize @90
-; __CxxRegisterExceptionObject @91
-; __CxxUnregisterExceptionObject @92
-; __DestructExceptionObject @93
- __RTCastToVoid=MSVCRT___RTCastToVoid @94
- __RTDynamicCast=MSVCRT___RTDynamicCast @95
- __RTtypeid=MSVCRT___RTtypeid @96
- __STRINGTOLD @97
-; ___lc_codepage_func @98
-; ___lc_collate_cp_func @99
-; ___lc_handle_func @100
-; ___mb_cur_max_func @101
- ___setlc_active_func @102
- ___unguarded_readlc_active_add_func @103
- __argc @104 DATA
- __argv @105 DATA
- __badioinfo @106 DATA
- __crtCompareStringA=kernel32.CompareStringA @107
- __crtCompareStringW=kernel32.CompareStringW @108
- __crtGetLocaleInfoW=kernel32.GetLocaleInfo @109
- __crtGetStringTypeW=kernel32.GetStringTypeW @110
- __crtLCMapStringA @111
-; __crtLCMapStringW @112
- __dllonexit @113
- __doserrno @114
- __fpecode @115
- __getmainargs @116
- __initenv @117
- __iob_func=__p__iob @118
- __isascii @119
- __iscsym @120
- __iscsymf @121
- __lc_codepage @122 DATA
- __lc_collate_cp @123 DATA
- __lc_handle @124 DATA
- __lconv_init @125
- __mb_cur_max @126 DATA
- __p___argc @127
- __p___argv @128
- __p___initenv @129
- __p___mb_cur_max @130
- __p___wargv @131
- __p___winitenv @132
- __p__acmdln @133
- __p__amblksiz @134
- __p__commode @135
- __p__daylight @136
- __p__dstbias @137
- __p__environ @138
-; __p__fileinfo @139
- __p__fmode @140
- __p__iob @141
-; __p__mbcasemap @142
- __p__mbctype @143
- __p__osver @144
- __p__pctype @145
- __p__pgmptr @146
- __p__pwctype @147
- __p__timezone @148
- __p__tzname @149
- __p__wcmdln @150
- __p__wenviron @151
- __p__winmajor @152
- __p__winminor @153
- __p__winver @154
- __p__wpgmptr @155
- __pctype_func @156
- __pioinfo @157 DATA
- __pwctype_func @158
- __pxcptinfoptrs @159
- __set_app_type @160
- __setlc_active @161 DATA
- __setusermatherr @162
- __threadhandle @163
- __threadid @164
- __toascii @165
- __unDName @166
- __unDNameEx @167
-; __uncaught_exception @42
- __unguarded_readlc_active @168 DATA
- __wargv @169 DATA
-; __wcserror @170
- __wgetmainargs @171
- __winitenv @172 DATA
- _abnormal_termination @173
-; _abs64 @174
- _access @175
- _acmdln @176 DATA
- _adj_fdiv_m16i @177
- _adj_fdiv_m32 @178
- _adj_fdiv_m32i @179
- _adj_fdiv_m64 @180
- _adj_fdiv_r @181
- _adj_fdivr_m16i @182
- _adj_fdivr_m32 @183
- _adj_fdivr_m32i @184
- _adj_fdivr_m64 @185
- _adj_fpatan @186
- _adj_fprem @187
- _adj_fprem1 @188
- _adj_fptan @189
- _adjust_fdiv @190 DATA
- _aexit_rtn @191
- _aligned_free @192
- _aligned_malloc @193
- _aligned_offset_malloc @194
- _aligned_offset_realloc @195
- _aligned_realloc @196
- _amsg_exit @197
- _assert @198
-; _atodbl @199
- _atoi64 @200
- _atoldbl @201
- _beep @202
- _beginthread @203
- _beginthreadex @204
- _c_exit @205
- _cabs @206
- _callnewh @207
- _cexit @208
- _cgets @209
-; _cgetws @210
- _chdir @211
- _chdrive @212
- _chgsign @213
- _chkesp @214
- _chmod @215
- _chsize @216
- _clearfp @217
- _close @218
- _commit @219
- _commode @220 DATA
- _control87 @221
- _controlfp @222
- _copysign @223
- _cprintf @224
- _cputs @225
-; _cputws @226
- _creat @227
- _cscanf @228
-; _ctime64 @229
- _ctype @230 DATA
- _cwait @231
-; _cwprintf @232
-; _cwscanf @233
- _daylight @234 DATA
- _dstbias @235 DATA
- _dup @236
- _dup2 @237
- _ecvt @238
- _endthread @239
- _endthreadex @240
- _environ @241 DATA
- _eof @242
- _errno @243
- _except_handler2 @244
- _except_handler3 @245
- _execl @246
- _execle @247
- _execlp @248
- _execlpe @249
- _execv @250
- _execve @251
- _execvp @252
- _execvpe @253
- _exit @254
- _expand @255
- _fcloseall @256
- _fcvt @257
- _fdopen @258
- _fgetchar @259
- _fgetwchar @260
- _filbuf @261
-; _fileinfo @262
- _filelength @263
- _filelengthi64 @264
- _fileno @265
- _findclose @266
- _findfirst @267
- _findfirst64 @268
- _findfirsti64 @269
- _findnext @270
- _findnext64 @271
- _findnexti64 @272
- _finite @273
- _flsbuf @274
- _flushall @275
- _fmode @276 DATA
- _fpclass @277
- _fpieee_flt @278
- _fpreset @279
- _fputchar @280
- _fputwchar @281
- _fsopen @282
- _fstat @283
- _fstat64 @284
- _fstati64 @285
- _ftime @286
-; _ftime64 @287
- _ftol @288
- _fullpath @289
- _futime @290
-; _futime64 @291
- _gcvt @292
-; _get_heap_handle @293
- _get_osfhandle @294
- _get_sbh_threshold @295
- _getch @296
- _getche @297
- _getcwd @298
- _getdcwd @299
- _getdiskfree @300
- _getdllprocaddr @301
- _getdrive @302
- _getdrives=kernel32.GetLogicalDrives @303
- _getmaxstdio @304
- _getmbcp @305
- _getpid=kernel32.GetCurrentProcessId @306
- _getsystime @307
- _getw @308
-; _getwch @309
-; _getwche @310
- _getws @311
- _global_unwind2 @312
- _gmtime64 @313
- _heapadd @314
- _heapchk @315
- _heapmin @316
- _heapset @317
-; _heapused @318
- _heapwalk @319
- _hypot @320
- _i64toa @321
- _i64tow @322
- _initterm @323
-; _inp @324
-; _inpd @325
-; _inpw @326
- _iob @327 DATA
- _isatty @328
- _isctype @329
- _ismbbalnum @330
- _ismbbalpha @331
- _ismbbgraph @332
- _ismbbkalnum @333
- _ismbbkana @334
-; _ismbbkprint @335
- _ismbbkpunct @336
- _ismbblead @337
- _ismbbprint @338
- _ismbbpunct @339
- _ismbbtrail @340
- _ismbcalnum @341
- _ismbcalpha @342
- _ismbcdigit @343
- _ismbcgraph @344
- _ismbchira @345
- _ismbckata @346
- _ismbcl0 @347
- _ismbcl1 @348
- _ismbcl2 @349
- _ismbclegal @350
- _ismbclower @351
- _ismbcprint @352
- _ismbcpunct @353
- _ismbcspace @354
- _ismbcsymbol @355
- _ismbcupper @356
- _ismbslead @357
- _ismbstrail @358
- _isnan @359
- _itoa @360
- _itow @361
-; FIXME: these aren't actually implemented in CRT
-; _j0 @362
-; _j1 @363
-; _jn @364
- _kbhit @365
- _lfind @366
- _loaddll @367
- _local_unwind2 @368
- _localtime64 @369
- _lock @370
- _locking @371
- _logb @372
- _longjmpex=longjmp @373
- _lrotl @374
- _lrotr @375
- _lsearch @376
- _lseek @377
- _lseeki64 @378
- _ltoa @379
- _ltow @380
- _makepath @381
- _mbbtombc @382
- _mbbtype @383
-; _mbcasemap @384
- _mbccpy @385
- _mbcjistojms @386
- _mbcjmstojis @387
- _mbclen @388
- _mbctohira @389
- _mbctokata @390
- _mbctolower @391
- _mbctombb @392
- _mbctoupper @393
- _mbctype @394 DATA
- _mbsbtype @395
- _mbscat @396
- _mbschr @397
- _mbscmp @398
- _mbscoll @399
- _mbscpy @400
- _mbscspn @401
- _mbsdec @402
- _mbsdup @403
- _mbsicmp @404
- _mbsicoll @405
- _mbsinc @406
- _mbslen @407
- _mbslwr @408
- _mbsnbcat @409
- _mbsnbcmp @410
- _mbsnbcnt @411
- _mbsnbcoll @412
- _mbsnbcpy @413
- _mbsnbicmp @414
- _mbsnbicoll @415
- _mbsnbset @416
- _mbsncat @417
- _mbsnccnt @418
- _mbsncmp @419
- _mbsncoll @420
- _mbsncpy @421
- _mbsnextc @422
- _mbsnicmp @423
- _mbsnicoll @424
- _mbsninc @425
- _mbsnset @426
- _mbspbrk @427
- _mbsrchr @428
- _mbsrev @429
- _mbsset @430
- _mbsspn @431
- _mbsspnp @432
- _mbsstr @433
- _mbstok @434
- _mbstrlen @435
- _mbsupr @436
- _memccpy @437
- _memicmp @438
- _mkdir @439
-; _mkgmtime @440
-; _mkgmtime64 @441
- _mktemp @442
-; _mktime64 @443
- _msize @444
- _nextafter @445
- _onexit @446
- _open @447
- _open_osfhandle @448
-; _osplatform @449
- _osver @450 DATA
-; _outp @451
-; _outpd @452
-; _outpw @453
- _pclose @454
- _pctype @455 DATA
- _pgmptr @456 DATA
- _pipe @457
- _popen @458
- _purecall @459
- _putch @460
- _putenv @461
- _putw @462
-; _putwch @463
- _putws @464
- _pwctype @465
- _read @466
-; _resetstkoflw @467
- _rmdir @468
- _rmtmp @469
- _rotl @470
-; _rotl64 @471
- _rotr @472
-; _rotr64 @473
- _safe_fdiv @474
- _safe_fdivr @475
- _safe_fprem @476
- _safe_fprem1 @477
- _scalb @478
-; _scprintf @479
-; _scwprintf @480
- _searchenv @481
- _seh_longjmp_unwind=_seh_longjmp_unwind@4 @482
-; _set_SSE2_enable @483
- _set_error_mode @484
- _set_sbh_threshold @485
- _seterrormode @486
- _setjmp @487
- _setjmp3 @488
- _setmaxstdio @489
- _setmbcp @490
- _setmode @491
- _setsystime @492
- _sleep @493
- _snprintf @494
-; _snscanf @495
- _snwprintf @496
-; _snwscanf @497
- _sopen @498
- _spawnl @499
- _spawnle @500
- _spawnlp @501
- _spawnlpe @502
- _spawnv @503
- _spawnve @504
- _spawnvp @505
- _spawnvpe @506
- _splitpath @507
- _stat @508
- _stat64 @509
- _stati64 @510
- _statusfp @511
- _strcmpi @512
- _strdate @513
- _strdup @514
- _strerror @515
- _stricmp @516
- _stricoll @517
- _strlwr @518
- _strncoll @519
- _strnicmp @520
- _strnicoll @521
- _strnset @522
- _strrev @523
- _strset @524
- _strtime @525
- _strtoi64 @526
- _strtoui64=strtoull @527
- _strupr @528
- _swab @529
- _sys_errlist @530 DATA
- _sys_nerr @531 DATA
- _tell @532
- _telli64 @533
- _tempnam @534
- _time64 @535
- _timezone @536 DATA
- _tolower @537
- _toupper @538
- _tzname @539 DATA
- _tzset @540
- _ui64toa @541
- _ui64tow @542
- _ultoa @543
- _ultow @544
- _umask @545
- _ungetch @546
-; _ungetwch @547
- _unlink @548
- _unloaddll @549
- _unlock @550
- _utime @551
-; _utime64 @552
-; _vscprintf @553
-; _vscwprintf @554
- _vsnprintf @555
- _vsnwprintf @556
- _waccess @557
- _wasctime @558
- _wchdir @559
- _wchmod @560
- _wcmdln @561
- _wcreat @562
- _wcsdup @563
-; _wcserror @564
- _wcsicmp @565
- _wcsicoll @566
- _wcslwr @567
- _wcsncoll @568
- _wcsnicmp @569
- _wcsnicoll @570
- _wcsnset @571
- _wcsrev @572
- _wcsset @573
- _wcstoi64 @574
- _wcstoui64 @575
- _wcsupr @576
- _wctime @577
-; _wctime64 @578
- _wctype @579
- _wenviron @580 DATA
- _wexecl @581
- _wexecle @582
- _wexeclp @583
- _wexeclpe @584
- _wexecv @585
- _wexecve @586
- _wexecvp @587
- _wexecvpe @588
- _wfdopen @589
- _wfindfirst @590
- _wfindfirst64 @591
- _wfindfirsti64 @592
- _wfindnext @593
- _wfindnext64 @594
- _wfindnexti64 @595
- _wfopen @596
- _wfreopen @597
- _wfsopen @598
- _wfullpath @599
- _wgetcwd @600
- _wgetdcwd @601
- _wgetenv @602
- _winmajor @603 DATA
- _winminor @604 DATA
- _winver @605 DATA
- _wmakepath @606
- _wmkdir @607
- _wmktemp @608
- _wopen @609
- _wperror @610
- _wpgmptr @611 DATA
- _wpopen @612
- _wputenv @613
- _wremove @614
- _wrename @615
- _write @616
- _wrmdir @617
- _wsearchenv @618
- _wsetlocale @619
- _wsopen @620
- _wspawnl @621
- _wspawnle @622
- _wspawnlp @623
- _wspawnlpe @624
- _wspawnv @625
- _wspawnve @626
- _wspawnvp @627
- _wspawnvpe @628
- _wsplitpath @629
- _wstat @630
- _wstat64 @631
- _wstati64 @632
- _wstrdate @633
- _wstrtime @634
- _wsystem @635
- _wtempnam @636
- _wtmpnam @637
-; _wtof @638
- _wtoi @639
- _wtoi64 @640
- _wtol @641
- _wunlink @642
- _wutime @643
-; _wutime64 @644
-; FIXME: these aren't actually implemented in CRT
-; _y0 @645
-; _y1 @646
-; _yn @647
- abort @648
- abs @649
- acos @650
- asctime @651
- asin @652
- atan @653
- atan2 @654
- atexit @655
- atof @656
- atoi @657
- atol @658
- bsearch @659
- calloc @660
- ceil @661
- clearerr @662
- clock @663
- cos @664
- cosh @665
- ctime @666
- difftime @667
- div @668
- exit @669
- exp @670
- fabs @671
- fclose @672
- feof @673
- ferror @674
- fflush @675
- fgetc @676
- fgetpos @677
- fgets @678
- fgetwc @679
- fgetws @680
- floor @681
- fmod @682
- fopen @683
- fprintf @684
- fputc @685
- fputs @686
- fputwc @687
- fputws @688
- fread @689
- free @690
- freopen @691
- frexp @692
- fscanf @693
- fseek @694
- fsetpos @695
- ftell @696
- fwprintf @697
- fwrite @698
- fwscanf @699
- getc @700
- getchar @701
- getenv @702
- gets @703
- getwc @704
- getwchar @705
- gmtime @706
- is_wctype @707
- isalnum @708
- isalpha @709
- iscntrl @710
- isdigit @711
- isgraph @712
- isleadbyte @713
- islower @714
- isprint @715
- ispunct @716
- isspace @717
- isupper @718
- iswalnum @719
- iswalpha @720
- iswascii @721
- iswcntrl @722
- iswctype @723
- iswdigit @724
- iswgraph @725
- iswlower @726
- iswprint @727
- iswpunct @728
- iswspace @729
- iswupper @730
- iswxdigit @731
- isxdigit @732
- labs @733
- ldexp @734
- ldiv @735
- localeconv @736
- localtime @737
- log @738
- log10 @739
- longjmp @740
- malloc @741
- mblen @742
- mbstowcs @743
- mbtowc @744
- memchr @745
- memcmp @746
- memcpy @747
- memmove @748
- memset @749
- mktime @750
- modf @751
- perror @752
- pow @753
- printf @754
- putc @755
- putchar @756
- puts @757
- putwc=fputwc @758
- putwchar=_fputwchar @759
- qsort @760
- raise @761
- rand @762
- realloc @763
- remove @764
- rename @765
- rewind @766
- scanf @767
- setbuf @768
- setlocale @769
- setvbuf @770
- signal @771
- sin @772
- sinh @773
- sprintf @774
- sqrt @775
- srand @776
- sscanf @777
- strcat @778
- strchr @779
- strcmp @780
- strcoll @781
- strcpy @782
- strcspn @783
- strerror @784
- strftime @785
- strlen @786
- strncat @787
- strncmp @788
- strncpy @789
- strpbrk @790
- strrchr @791
- strspn @792
- strstr @793
- strtod @794
- strtok @795
- strtol @796
- strtoul @797
- strxfrm @798
- swprintf @799
- swscanf @800
- system @801
- tan @802
- tanh @803
- time @804
- tmpfile @805
- tmpnam @806
- tolower @807
- toupper @808
- towlower @809
- towupper @810
- ungetc @811
- ungetwc @812
- vfprintf @813
- vfwprintf @814
- vprintf @815
- vsprintf @816
- vswprintf @817
- vwprintf @818
- wcscat @819
- wcschr @820
- wcscmp @821
- wcscoll @822
- wcscpy @823
- wcscspn @824
- wcsftime @825
- wcslen @826
- wcsncat @827
- wcsncmp @828
- wcsncpy @829
- wcspbrk @830
- wcsrchr @831
- wcsspn @832
- wcsstr @833
- wcstod @834
- wcstok @835
- wcstol @836
- wcstombs @837
- wcstoul @838
- wcsxfrm @839
- wctomb @840
- wprintf @841
- wscanf @842
-
- _mbsnbcpy_s
- wcscpy_s
- wcsncpy_s
- _wcsupr_s
- _ftol2=_ftol
- _ftol2_sse=_ftol
- strcat_s
- strcpy_s
-
- _swprintf=swprintf
diff --git a/dll/win32/msvcrt/msvcrt.rbuild b/dll/win32/msvcrt/msvcrt.rbuild
index 230907073d4..513de0f5520 100644
--- a/dll/win32/msvcrt/msvcrt.rbuild
+++ b/dll/win32/msvcrt/msvcrt.rbuild
@@ -1,5 +1,5 @@
-
+
.
include
diff --git a/dll/win32/msvcrt/msvcrt.spec b/dll/win32/msvcrt/msvcrt.spec
new file mode 100644
index 00000000000..98bdd1ccf88
--- /dev/null
+++ b/dll/win32/msvcrt/msvcrt.spec
@@ -0,0 +1,1407 @@
+# msvcrt.dll - MS VC++ Run Time Library
+
+@ cdecl $I10_OUTPUT() MSVCRT_I10_OUTPUT
+@ cdecl -i386 -norelay ??0__non_rtti_object@@QAE@ABV0@@Z(ptr) __thiscall_MSVCRT___non_rtti_object_copy_ctor
+@ cdecl -i386 -norelay ??0__non_rtti_object@@QAE@PBD@Z(ptr) __thiscall_MSVCRT___non_rtti_object_ctor
+@ cdecl -i386 -norelay ??0bad_cast@@AAE@PBQBD@Z(ptr) __thiscall_MSVCRT_bad_cast_ctor
+@ cdecl -i386 -norelay ??0bad_cast@@QAE@ABQBD@Z(ptr) __thiscall_MSVCRT_bad_cast_ctor
+@ cdecl -i386 -norelay ??0bad_cast@@QAE@ABV0@@Z(ptr) __thiscall_MSVCRT_bad_cast_copy_ctor
+@ cdecl -i386 -norelay ??0bad_cast@@QAE@PBD@Z(ptr) __thiscall_MSVCRT_bad_cast_ctor_charptr
+@ cdecl -i386 -norelay ??0bad_typeid@@QAE@ABV0@@Z(ptr) __thiscall_MSVCRT_bad_typeid_copy_ctor
+@ cdecl -i386 -norelay ??0bad_typeid@@QAE@PBD@Z(ptr) __thiscall_MSVCRT_bad_typeid_ctor
+@ cdecl -i386 -norelay ??0exception@@QAE@ABQBD@Z(ptr) __thiscall_MSVCRT_exception_ctor
+@ cdecl -i386 -norelay ??0exception@@QAE@ABQBDH@Z(ptr long) __thiscall_MSVCRT_exception_ctor_noalloc
+@ cdecl -i386 -norelay ??0exception@@QAE@ABV0@@Z(ptr) __thiscall_MSVCRT_exception_copy_ctor
+@ cdecl -i386 -norelay ??0exception@@QAE@XZ() __thiscall_MSVCRT_exception_default_ctor
+@ cdecl -i386 -norelay ??1__non_rtti_object@@UAE@XZ() __thiscall_MSVCRT___non_rtti_object_dtor
+@ cdecl -i386 -norelay ??1bad_cast@@UAE@XZ() __thiscall_MSVCRT_bad_cast_dtor
+@ cdecl -i386 -norelay ??1bad_typeid@@UAE@XZ() __thiscall_MSVCRT_bad_typeid_dtor
+@ cdecl -i386 -norelay ??1exception@@UAE@XZ() __thiscall_MSVCRT_exception_dtor
+@ cdecl -i386 -norelay ??1type_info@@UAE@XZ() __thiscall_MSVCRT_type_info_dtor
+@ cdecl ??2@YAPAXI@Z(long) MSVCRT_operator_new
+# @ cdecl ??2@YAPAXIHPBDH@Z(long long str long) MSVCRT_operator_new_dbg
+@ cdecl ??3@YAXPAX@Z(ptr) MSVCRT_operator_delete
+@ cdecl -i386 -norelay ??4__non_rtti_object@@QAEAAV0@ABV0@@Z(ptr) __thiscall_MSVCRT___non_rtti_object_opequals
+@ cdecl -i386 -norelay ??4bad_cast@@QAEAAV0@ABV0@@Z(ptr) __thiscall_MSVCRT_bad_cast_opequals
+@ cdecl -i386 -norelay ??4bad_typeid@@QAEAAV0@ABV0@@Z(ptr) __thiscall_MSVCRT_bad_typeid_opequals
+@ cdecl -i386 -norelay ??4exception@@QAEAAV0@ABV0@@Z(ptr) __thiscall_MSVCRT_exception_opequals
+@ cdecl -i386 -norelay ??8type_info@@QBEHABV0@@Z(ptr) __thiscall_MSVCRT_type_info_opequals_equals
+@ cdecl -i386 -norelay ??9type_info@@QBEHABV0@@Z(ptr) __thiscall_MSVCRT_type_info_opnot_equals
+@ extern -i386 ??_7__non_rtti_object@@6B@ MSVCRT___non_rtti_object_vtable
+@ extern -i386 ??_7bad_cast@@6B@ MSVCRT_bad_cast_vtable
+@ extern -i386 ??_7bad_typeid@@6B@ MSVCRT_bad_typeid_vtable
+@ extern -i386 ??_7exception@@6B@ MSVCRT_exception_vtable
+@ cdecl -i386 -norelay ??_E__non_rtti_object@@UAEPAXI@Z(long) __thiscall_MSVCRT___non_rtti_object_vector_dtor
+@ cdecl -i386 -norelay ??_Ebad_cast@@UAEPAXI@Z(long) __thiscall_MSVCRT_bad_cast_vector_dtor
+@ cdecl -i386 -norelay ??_Ebad_typeid@@UAEPAXI@Z(long) __thiscall_MSVCRT_bad_typeid_vector_dtor
+@ cdecl -i386 -norelay ??_Eexception@@UAEPAXI@Z(long) __thiscall_MSVCRT_exception_vector_dtor
+@ cdecl -i386 -norelay ??_Fbad_cast@@QAEXXZ() __thiscall_MSVCRT_bad_cast_default_ctor
+@ cdecl -i386 -norelay ??_Fbad_typeid@@QAEXXZ() __thiscall_MSVCRT_bad_typeid_default_ctor
+@ cdecl -i386 -norelay ??_G__non_rtti_object@@UAEPAXI@Z(long) __thiscall_MSVCRT___non_rtti_object_scalar_dtor
+@ cdecl -i386 -norelay ??_Gbad_cast@@UAEPAXI@Z(long) __thiscall_MSVCRT_bad_cast_scalar_dtor
+@ cdecl -i386 -norelay ??_Gbad_typeid@@UAEPAXI@Z(long) __thiscall_MSVCRT_bad_typeid_scalar_dtor
+@ cdecl -i386 -norelay ??_Gexception@@UAEPAXI@Z(long) __thiscall_MSVCRT_exception_scalar_dtor
+@ cdecl ??_U@YAPAXI@Z(long) MSVCRT_operator_new
+# @ cdecl ??_U@YAPAXIHPBDH@Z(long long str long) MSVCRT_operator_new_dbg
+@ cdecl ??_V@YAXPAX@Z(ptr) MSVCRT_operator_delete
+@ cdecl ?_query_new_handler@@YAP6AHI@ZXZ() MSVCRT__query_new_handler
+@ cdecl ?_query_new_mode@@YAHXZ() MSVCRT__query_new_mode
+@ cdecl ?_set_new_handler@@YAP6AHI@ZP6AHI@Z@Z(ptr) MSVCRT__set_new_handler
+@ cdecl ?_set_new_mode@@YAHH@Z(long) MSVCRT__set_new_mode
+@ cdecl ?_set_se_translator@@YAP6AXIPAU_EXCEPTION_POINTERS@@@ZP6AXI0@Z@Z(ptr) MSVCRT__set_se_translator
+@ cdecl -i386 -norelay ?before@type_info@@QBEHABV1@@Z(ptr) __thiscall_MSVCRT_type_info_before
+@ cdecl -i386 -norelay ?name@type_info@@QBEPBDXZ() __thiscall_MSVCRT_type_info_name
+@ cdecl -i386 -norelay ?raw_name@type_info@@QBEPBDXZ() __thiscall_MSVCRT_type_info_raw_name
+@ cdecl ?set_new_handler@@YAP6AXXZP6AXXZ@Z(ptr) MSVCRT_set_new_handler
+@ cdecl ?set_terminate@@YAP6AXXZP6AXXZ@Z(ptr) MSVCRT_set_terminate
+@ cdecl ?set_unexpected@@YAP6AXXZP6AXXZ@Z(ptr) MSVCRT_set_unexpected
+@ cdecl ?terminate@@YAXXZ() MSVCRT_terminate
+@ cdecl ?unexpected@@YAXXZ() MSVCRT_unexpected
+@ cdecl -i386 -norelay ?what@exception@@UBEPBDXZ() __thiscall_MSVCRT_what_exception
+@ cdecl -arch=i386 _CIacos()
+@ cdecl -arch=i386 _CIasin()
+@ cdecl -arch=i386 _CIatan()
+@ cdecl -arch=i386 _CIatan2()
+@ cdecl -arch=i386 _CIcos()
+@ cdecl -arch=i386 _CIcosh()
+@ cdecl -arch=i386 _CIexp()
+@ cdecl -arch=i386 _CIfmod()
+@ cdecl -arch=i386 _CIlog()
+@ cdecl -arch=i386 _CIlog10()
+@ cdecl -arch=i386 _CIpow()
+@ cdecl -arch=i386 _CIsin()
+@ cdecl -arch=i386 _CIsinh()
+@ cdecl -arch=i386 _CIsqrt()
+@ cdecl -arch=i386 _CItan()
+@ cdecl -arch=i386 _CItanh()
+# stub _CrtCheckMemory
+# stub _CrtDbgBreak
+# stub _CrtDbgReport
+# stub _CrtDbgReportV
+# stub _CrtDbgReportW
+# stub _CrtDbgReportWV
+# stub _CrtDoForAllClientObjects
+# stub _CrtDumpMemoryLeaks
+# stub _CrtIsMemoryBlock
+# stub _CrtIsValidHeapPointer
+# stub _CrtIsValidPointer
+# stub _CrtMemCheckpoint
+# stub _CrtMemDifference
+# stub _CrtMemDumpAllObjectsSince
+# stub _CrtMemDumpStatistics
+# stub _CrtReportBlockType
+# stub _CrtSetAllocHook
+# stub _CrtSetBreakAlloc
+# stub _CrtSetDbgBlockType
+# stub _CrtSetDbgFlag
+# stub _CrtSetDumpClient
+# stub _CrtSetReportFile
+# stub _CrtSetReportHook
+# stub _CrtSetReportHook2
+# stub _CrtSetReportMode
+@ cdecl _CxxThrowException(long long)
+@ cdecl -i386 -norelay _EH_prolog()
+@ cdecl _Getdays()
+@ cdecl _Getmonths()
+@ cdecl _Gettnames()
+@ extern _HUGE _HUGE
+@ cdecl _Strftime(str long str ptr ptr)
+@ cdecl _XcptFilter(long ptr)
+@ cdecl __CppXcptFilter(long ptr)
+# stub __CxxCallUnwindDelDtor
+# stub __CxxCallUnwindDtor
+# stub __CxxCallUnwindVecDtor
+@ cdecl __CxxDetectRethrow(ptr)
+# stub __CxxExceptionFilter
+@ cdecl -i386 -norelay __CxxFrameHandler(ptr ptr ptr ptr)
+@ cdecl -i386 -norelay __CxxFrameHandler2(ptr ptr ptr ptr) __CxxFrameHandler
+@ cdecl -i386 -norelay __CxxFrameHandler3(ptr ptr ptr ptr) __CxxFrameHandler
+@ stdcall -arch=x86_64 __C_specific_handler(ptr long ptr ptr) ntdll.__C_specific_handler
+@ stdcall -i386 __CxxLongjmpUnwind(ptr)
+@ cdecl __CxxQueryExceptionSize()
+# stub __CxxRegisterExceptionObject
+# stub __CxxUnregisterExceptionObject
+# stub __DestructExceptionObject
+@ cdecl __RTCastToVoid(ptr) MSVCRT___RTCastToVoid
+@ cdecl __RTDynamicCast(ptr long ptr ptr long) MSVCRT___RTDynamicCast
+@ cdecl __RTtypeid(ptr) MSVCRT___RTtypeid
+@ cdecl __STRINGTOLD(ptr ptr str long)
+# @ cdecl ___lc_codepage_func()
+# @ cdecl ___lc_collate_cp_func()
+# @ cdecl ___lc_handle_func()
+# @ cdecl ___mb_cur_max_func() MSVCRT___mb_cur_max_func
+@ cdecl ___setlc_active_func()
+@ cdecl ___unguarded_readlc_active_add_func()
+@ extern __argc __argc
+@ extern __argv __argv
+@ extern __badioinfo __badioinfo
+@ cdecl __crtCompareStringA(long long str long str long) kernel32.CompareStringA
+@ cdecl __crtCompareStringW(long long wstr long wstr long) kernel32.CompareStringW
+@ cdecl __crtGetLocaleInfoW(long long ptr long) kernel32.GetLocaleInfo
+@ cdecl __crtGetStringTypeW(long long wstr long ptr) kernel32.GetStringTypeW
+@ cdecl __crtLCMapStringA(long long str long ptr long long long)
+# stub __crtLCMapStringW
+@ cdecl __dllonexit(ptr ptr ptr)
+@ cdecl __doserrno() __doserrno
+@ cdecl __fpecode()
+@ stub __get_app_type
+@ cdecl __getmainargs(ptr ptr ptr long ptr)
+@ extern __initenv __initenv
+@ cdecl __iob_func() __p__iob
+@ cdecl __isascii(long) __isascii
+@ cdecl __iscsym(long) __iscsym
+@ cdecl __iscsymf(long) __iscsymf
+@ extern __lc_codepage __lc_codepage
+@ stub __lc_collate
+@ extern __lc_collate_cp __lc_collate_cp
+@ extern __lc_handle __lc_handle
+@ cdecl __lconv_init()
+# stub __libm_sse2_acos
+# stub __libm_sse2_acosf
+# stub __libm_sse2_asin
+# stub __libm_sse2_asinf
+# stub __libm_sse2_atan
+# stub __libm_sse2_atan2
+# stub __libm_sse2_atanf
+# stub __libm_sse2_cos
+# stub __libm_sse2_cosf
+# stub __libm_sse2_exp
+# stub __libm_sse2_expf
+# stub __libm_sse2_log
+# stub __libm_sse2_log10
+# stub __libm_sse2_log10f
+# stub __libm_sse2_logf
+# stub __libm_sse2_pow
+# stub __libm_sse2_powf
+# stub __libm_sse2_sin
+# stub __libm_sse2_sinf
+# stub __libm_sse2_tan
+# stub __libm_sse2_tanf
+@ extern __mb_cur_max __mb_cur_max
+@ cdecl -arch=i386 __p___argc()
+@ cdecl -arch=i386 __p___argv()
+@ cdecl -arch=i386 __p___initenv()
+@ cdecl -arch=i386 __p___mb_cur_max()
+@ cdecl -arch=i386 __p___wargv()
+@ cdecl -arch=i386 __p___winitenv()
+@ cdecl -arch=i386 __p__acmdln()
+@ cdecl -arch=i386 __p__amblksiz()
+@ cdecl -arch=i386 __p__commode()
+@ cdecl -arch=i386 __p__daylight()
+@ cdecl -arch=i386 __p__dstbias()
+@ cdecl -arch=i386 __p__environ()
+@ stub -arch=i386 __p__fileinfo #()
+@ cdecl -arch=i386 __p__fmode()
+@ cdecl -arch=i386 __p__iob()
+@ stub -arch=i386 __p__mbcasemap #()
+@ cdecl -arch=i386 __p__mbctype()
+@ cdecl -arch=i386 __p__osver()
+@ cdecl -arch=i386 __p__pctype() __pctype_func
+@ cdecl -arch=i386 __p__pgmptr()
+@ stub -arch=i386 __p__pwctype #()
+@ cdecl -arch=i386 __p__timezone() __p__timezone
+@ cdecl -arch=i386 __p__tzname()
+@ cdecl -arch=i386 __p__wcmdln()
+@ cdecl -arch=i386 __p__wenviron()
+@ cdecl -arch=i386 __p__winmajor()
+@ cdecl -arch=i386 __p__winminor()
+@ cdecl -arch=i386 __p__winver()
+@ cdecl -arch=i386 __p__wpgmptr()
+@ cdecl __pctype_func() __pctype_func
+@ extern __pioinfo __pioinfo
+# stub __pwctype_func
+@ stub __pxcptinfoptrs #()
+@ cdecl __set_app_type(long)
+@ extern __setlc_active
+@ cdecl __setusermatherr(ptr)
+# stub __strncnt
+@ cdecl __threadhandle() kernel32.GetCurrentThread
+@ cdecl __threadid() kernel32.GetCurrentThreadId
+@ cdecl __toascii(long)
+@ cdecl __uncaught_exception()
+@ cdecl __unDName(ptr str long ptr ptr long)
+@ cdecl __unDNameEx(ptr str long ptr ptr ptr long)
+@ extern __unguarded_readlc_active
+@ extern __wargv __wargv
+# stub __wcserror
+# stub __wcserror_s
+# stub __wcsncnt
+@ cdecl __wgetmainargs(ptr ptr ptr long ptr)
+@ extern __winitenv
+@ cdecl _abnormal_termination()
+# stub _abs64
+@ cdecl _access(str long)
+# stub _access_s
+@ extern _acmdln _acmdln
+@ stdcall -arch=i386 _adj_fdiv_m16i(long)
+@ stdcall -arch=i386 _adj_fdiv_m32(long)
+@ stdcall -arch=i386 _adj_fdiv_m32i(long)
+@ stdcall -arch=i386 _adj_fdiv_m64(double)
+@ cdecl -arch=i386 _adj_fdiv_r()
+@ stdcall -arch=i386 _adj_fdivr_m16i(long)
+@ stdcall -arch=i386 _adj_fdivr_m32(long)
+@ stdcall -arch=i386 _adj_fdivr_m32i(long)
+@ stdcall -arch=i386 _adj_fdivr_m64(double)
+@ cdecl -arch=i386 _adj_fpatan()
+@ cdecl -arch=i386 _adj_fprem()
+@ cdecl -arch=i386 _adj_fprem1()
+@ cdecl -arch=i386 _adj_fptan()
+@ extern -arch=i386 _adjust_fdiv
+# extern _aexit_rtn
+@ cdecl _aligned_free(ptr)
+# stub _aligned_free_dbg
+@ cdecl _aligned_malloc(long long)
+# stub _aligned_malloc_dbg
+@ cdecl _aligned_offset_malloc(long long long)
+# stub _aligned_offset_malloc_dbg
+@ cdecl _aligned_offset_realloc(ptr long long long)
+# stub _aligned_offset_realloc_dbg
+@ cdecl _aligned_realloc(ptr long long)
+# stub _aligned_realloc_dbg
+@ cdecl _amsg_exit(long)
+@ cdecl _assert(str str long)
+@ stub _atodbl #(ptr str)
+# stub _atodbl_l
+# @ cdecl _atof_l(str ptr)
+# stub _atoflt_l
+@ cdecl -ret64 _atoi64(str)
+# stub _atoi64_l
+# stub _atoi_l
+# stub _atol_l
+@ cdecl _atoldbl(ptr str)
+# stub _atoldbl_l
+@ cdecl _beep(long long)
+@ cdecl _beginthread (ptr long ptr)
+@ cdecl _beginthreadex (ptr long ptr ptr long ptr)
+@ cdecl _c_exit()
+@ cdecl _cabs(long)
+@ cdecl _callnewh(long)
+# stub _calloc_dbg
+@ cdecl _cexit()
+@ cdecl _cgets(str)
+# stub _cgets_s
+# stub _cgetws
+# stub _cgetws_s
+@ cdecl _chdir(str)
+@ cdecl _chdrive(long)
+@ cdecl _chgsign(double)
+@ cdecl -i386 -norelay _chkesp()
+@ cdecl _chmod(str long)
+@ cdecl _chsize(long long)
+# stub _chsize_s
+# stub _chvalidator
+# stub _chvalidator_l
+@ cdecl _clearfp()
+@ cdecl _close(long)
+@ cdecl _commit(long)
+@ extern _commode
+@ cdecl _control87(long long)
+@ cdecl _controlfp(long long)
+# @ cdecl _controlfp_s(ptr long long)
+@ cdecl _copysign( double double )
+@ varargs _cprintf(str)
+# stub _cprintf_l
+# stub _cprintf_p
+# stub _cprintf_p_l
+# stub _cprintf_s
+# stub _cprintf_s_l
+@ cdecl _cputs(str)
+# stub _cputws
+@ cdecl _creat(str long)
+# stub _crtAssertBusy
+# stub _crtBreakAlloc
+# stub _crtDbgFlag
+@ varargs _cscanf(str)
+# @ varargs _cscanf_l(str ptr)
+# @ varargs _cscanf_s(str)
+# @ varargs _cscanf_s_l(str ptr)
+@ cdecl _ctime32(ptr)
+# stub _ctime32_s
+@ cdecl _ctime64(ptr)
+# stub _ctime64_s
+@ extern _ctype
+@ cdecl _cwait(ptr long long)
+# stub _cwprintf
+# stub _cwprintf_l
+# stub _cwprintf_p
+# stub _cwprintf_p_l
+# stub _cwprintf_s
+# stub _cwprintf_s_l
+# @ varargs _cwscanf(wstr)
+# @ varargs _cwscanf_l(wstr ptr)
+# @ varargs _cwscanf_s(wstr)
+# @ varargs _cwscanf_s_l(wstr ptr)
+@ extern _daylight
+@ cdecl _difftime32(long long)
+@ cdecl _difftime64(long long)
+@ extern _dstbias
+@ cdecl _dup (long)
+@ cdecl _dup2 (long long)
+@ cdecl _ecvt(double long ptr ptr)
+# stub _ecvt_s
+@ cdecl _endthread ()
+@ cdecl _endthreadex(long)
+@ extern _environ
+@ cdecl _eof(long)
+@ cdecl _errno()
+@ cdecl -i386 _except_handler2(ptr ptr ptr ptr)
+@ cdecl -i386 _except_handler3(ptr ptr ptr ptr)
+@ cdecl -i386 _except_handler4_common(ptr ptr ptr ptr ptr ptr)
+@ varargs _execl(str str)
+@ varargs _execle(str str)
+@ varargs _execlp(str str)
+@ varargs _execlpe(str str)
+@ cdecl _execv(str ptr)
+@ cdecl _execve(str ptr ptr)
+@ cdecl _execvp(str ptr)
+@ cdecl _execvpe(str ptr ptr)
+@ cdecl _exit(long) _exit
+@ cdecl _expand(ptr long)
+# stub _expand_dbg
+@ cdecl _fcloseall()
+@ cdecl _fcvt(double long ptr ptr)
+# stub _fcvt_s
+@ cdecl _fdopen(long str)
+@ cdecl _fgetchar()
+@ cdecl _fgetwchar()
+@ cdecl _filbuf(ptr)
+# extern _fileinfo
+@ cdecl _filelength(long)
+@ cdecl -ret64 _filelengthi64(long)
+@ cdecl _fileno(ptr)
+@ cdecl _findclose(long)
+@ cdecl _findfirst(str ptr)
+@ cdecl _findfirst64(str ptr)
+@ cdecl _findfirsti64(str ptr)
+@ cdecl _findnext(long ptr)
+@ cdecl _findnext64(long ptr)
+@ cdecl _findnexti64(long ptr)
+@ cdecl _finite(double)
+@ cdecl _flsbuf(long ptr)
+@ cdecl _flushall()
+@ extern _fmode
+@ cdecl _fpclass(double)
+@ stub _fpieee_flt #(long ptr ptr)
+@ cdecl _fpreset()
+# stub _fprintf_l
+# stub _fprintf_p
+# stub _fprintf_p_l
+# stub _fprintf_s_l
+@ cdecl _fputchar(long)
+@ cdecl _fputwchar(long)
+# stub _free_dbg
+# stub _freea
+# stub _freea_s
+# stub _fscanf_l
+# @ varargs _fscanf_l(ptr str ptr)
+# @ varargs _fscanf_s_l(ptr str ptr)
+# stub _fseeki64
+@ cdecl _fsopen(str str long)
+@ cdecl _fstat(long ptr)
+@ cdecl _fstat64(long ptr)
+@ cdecl _fstati64(long ptr)
+@ cdecl _ftime(ptr)
+@ cdecl _ftime32(ptr)
+# stub _ftime32_s
+@ cdecl _ftime64(ptr)
+# stub _ftime64_s
+@ cdecl -ret64 _ftol()
+@ cdecl -ret64 _ftol2() _ftol
+@ cdecl -ret64 _ftol2_sse() _ftol #FIXME: SSE variant should be implemented
+# stub _ftol2_sse_excpt
+@ cdecl _fullpath(ptr str long)
+# stub _fullpath_dbg
+@ cdecl _futime(long ptr)
+@ cdecl _futime32(long ptr)
+@ cdecl _futime64(long ptr)
+# stub _fwprintf_l
+# stub _fwprintf_p
+# stub _fwprintf_p_l
+# stub _fwprintf_s_l
+# @ varargs _fwscanf_l(ptr wstr ptr)
+# @ varargs _fwscanf_s_l(ptr wstr ptr)
+@ cdecl _gcvt(double long str)
+# stub _gcvt_s
+# stub _get_doserrno
+# stub _get_environ
+# stub _get_errno
+# stub _get_fileinfo
+# stub _get_fmode
+# @ cdecl _get_heap_handle()
+@ cdecl _get_osfhandle(long)
+# stub _get_osplatform
+# stub _get_osver
+# stub _get_output_format
+# stub _get_pgmptr
+@ cdecl _get_sbh_threshold()
+# stub _get_wenviron
+# stub _get_winmajor
+# stub _get_winminor
+# stub _get_winver
+# stub _get_wpgmptr
+@ stub _get_terminate
+@ stub _get_unexpected
+@ cdecl _getch()
+@ cdecl _getche()
+@ cdecl _getcwd(str long)
+@ cdecl _getdcwd(long str long)
+@ cdecl _getdiskfree(long ptr)
+@ cdecl _getdllprocaddr(long str long)
+@ cdecl _getdrive()
+@ cdecl _getdrives() kernel32.GetLogicalDrives
+@ cdecl _getmaxstdio()
+@ cdecl _getmbcp()
+@ cdecl _getpid() kernel32.GetCurrentProcessId
+@ stub _getsystime #(ptr)
+@ cdecl _getw(ptr)
+# stub _getwch
+# stub _getwche
+@ cdecl _getws(ptr)
+@ cdecl -i386 _global_unwind2(ptr)
+@ cdecl _gmtime32(ptr)
+# stub _gmtime32_s
+@ cdecl _gmtime64(ptr)
+# stub _gmtime64_s
+@ cdecl _heapadd (ptr long)
+@ cdecl _heapchk()
+@ cdecl _heapmin()
+@ cdecl _heapset(long)
+@ stub _heapused #(ptr ptr)
+@ cdecl _heapwalk(ptr)
+@ cdecl _hypot(double double)
+@ cdecl _i64toa(long long ptr long)
+# stub _i64toa_s
+@ cdecl _i64tow(long long ptr long)
+# stub _i64tow_s
+@ cdecl _initterm(ptr ptr)
+# stub _initterm_e
+@ stub _inp #(long) -i386
+@ stub _inpd #(long) -i386
+@ stub _inpw #(long) -i386
+# @ cdecl _invalid_parameter(wstr wstr wstr long long)
+@ extern _iob
+# stub _isalnum_l
+# stub _isalpha_l
+@ cdecl _isatty(long)
+# stub _iscntrl_l
+@ cdecl _isctype(long long)
+# stub _isctype_l
+# stub _isdigit_l
+# stub _isgraph_l
+# stub _isleadbyte_l
+# stub _islower_l
+@ stub _ismbbalnum #(long)
+# stub _ismbbalnum_l
+@ stub _ismbbalpha #(long)
+# stub _ismbbalpha_l
+@ stub _ismbbgraph #(long)
+# stub _ismbbgraph_l
+@ stub _ismbbkalnum #(long)
+# stub _ismbbkalnum_l
+@ cdecl _ismbbkana(long)
+# stub _ismbbkana_l
+@ stub _ismbbkprint #(long)
+# stub _ismbbkprint_l
+@ stub _ismbbkpunct #(long)
+# stub _ismbbkpunct_l
+@ cdecl _ismbblead(long)
+# stub _ismbblead_l
+@ stub _ismbbprint #(long)
+# stub _ismbbprint_l
+@ stub _ismbbpunct #(long)
+# stub _ismbbpunct_l
+@ cdecl _ismbbtrail(long)
+# stub _ismbbtrail_l
+@ cdecl _ismbcalnum(long)
+# stub _ismbcalnum_l
+@ cdecl _ismbcalpha(long)
+# stub _ismbcalpha_l
+@ cdecl _ismbcdigit(long)
+# stub _ismbcdigit_l
+@ cdecl _ismbcgraph(long)
+# stub _ismbcgraph_l
+@ cdecl _ismbchira(long)
+# stub _ismbchira_l
+@ cdecl _ismbckata(long)
+# stub _ismbckata_l
+@ stub _ismbcl0 #(long)
+# stub _ismbcl0_l
+@ stub _ismbcl1 #(long)
+# stub _ismbcl1_l
+@ stub _ismbcl2 #(long)
+# stub _ismbcl2_l
+@ cdecl _ismbclegal(long)
+# stub _ismbclegal_l
+@ cdecl _ismbclower(long)
+# stub _ismbclower_l
+@ cdecl _ismbcprint(long)
+# stub _ismbcprint_l
+@ cdecl _ismbcpunct(long)
+# stub _ismbcpunct_l
+@ cdecl _ismbcspace(long)
+# stub _ismbcspace_l
+@ cdecl _ismbcsymbol(long)
+# stub _ismbcsymbol_l
+@ cdecl _ismbcupper(long)
+# stub _ismbcupper_l
+@ cdecl _ismbslead(ptr ptr)
+# stub _ismbslead_l
+@ cdecl _ismbstrail(ptr ptr)
+# stub _ismbstrail_l
+@ cdecl _isnan(double)
+# stub _isprint_l
+# stub _isspace_l
+# stub _isupper_l
+# stub _iswalnum_l
+# stub _iswalpha_l
+# stub _iswcntrl_l
+# stub _iswctype_l
+# stub _iswdigit_l
+# stub _iswgraph_l
+# stub _iswlower_l
+# stub _iswprint_l
+# stub _iswpunct_l
+# stub _iswspace_l
+# stub _iswupper_l
+# stub _iswxdigit_l
+# stub _isxdigit_l
+@ cdecl _itoa(long ptr long)
+# stub _itoa_s
+@ cdecl _itow(long ptr long)
+# stub _itow_s
+#@ cdecl _j0(double)
+#@ cdecl _j1(double)
+#@ cdecl _jn(long double)
+@ cdecl _kbhit()
+@ cdecl _lfind(ptr ptr ptr long ptr)
+# stub _lfind_s
+@ cdecl _loaddll(str)
+@ cdecl -i386 _local_unwind2(ptr long)
+@ cdecl -i386 _local_unwind4(ptr ptr long) msvcrt_local_unwind4
+@ cdecl _localtime32(ptr)
+# stub _localtime32_s
+@ cdecl _localtime64(ptr)
+# stub _localtime64_s
+@ cdecl _lock(long)
+@ cdecl _locking(long long long)
+@ cdecl _logb( double )
+@ cdecl -i386 _longjmpex(ptr long) longjmp
+@ cdecl _lrotl(long long)
+@ cdecl _lrotr(long long)
+@ cdecl _lsearch(ptr ptr long long ptr)
+# stub _lsearch_s
+@ cdecl _lseek(long long long)
+@ cdecl -ret64 _lseeki64(long double long)
+@ cdecl _ltoa(long ptr long)
+# stub _ltoa_s
+@ cdecl _ltow(long ptr long)
+# stub _ltow_s
+@ cdecl _makepath(ptr str str str str)
+# stub _makepath_s
+# stub _malloc_dbg
+@ cdecl _matherr(ptr)
+@ cdecl _mbbtombc(long)
+# stub _mbbtombc_l
+@ cdecl _mbbtype(long long)
+# extern _mbcasemap
+@ cdecl _mbccpy (str str)
+# stub _mbccpy_l
+# stub _mbccpy_s
+# stub _mbccpy_s_l
+@ cdecl _mbcjistojms (long)
+# stub _mbcjistojms_l
+@ stub _mbcjmstojis #(long)
+# stub _mbcjmstojis_l
+@ cdecl _mbclen(ptr)
+# stub _mbclen_l
+@ stub _mbctohira #(long)
+# stub _mbctohira_l
+@ stub _mbctokata #(long)
+# stub _mbctokata_l
+@ cdecl _mbctolower(long)
+# stub _mbctolower_l
+@ cdecl _mbctombb(long)
+# stub _mbctombb_l
+@ cdecl _mbctoupper(long)
+# stub _mbctoupper_l
+@ extern _mbctype
+# stub _mblen_l
+@ cdecl _mbsbtype(str long)
+# stub _mbsbtype_l
+@ cdecl _mbscat(str str)
+# stub _mbscat_s
+# stub _mbscat_s_l
+@ cdecl _mbschr(str long)
+# stub _mbschr_l
+@ cdecl _mbscmp(str str)
+# stub _mbscmp_l
+@ cdecl _mbscoll(str str)
+# stub _mbscoll_l
+@ cdecl _mbscpy(ptr str)
+# stub _mbscpy_s
+# stub _mbscpy_s_l
+@ cdecl _mbscspn (str str)
+# stub _mbscspn_l
+@ cdecl _mbsdec(ptr ptr)
+# stub _mbsdec_l
+@ cdecl _mbsdup(str) _strdup
+# stub _strdup_dbg
+@ cdecl _mbsicmp(str str)
+# stub _mbsicmp_l
+@ cdecl _mbsicoll(str str)
+# stub _mbsicoll_l
+@ cdecl _mbsinc(str)
+# stub _mbsinc_l
+@ cdecl _mbslen(str)
+# stub _mbslen_l
+@ cdecl _mbslwr(str)
+# stub _mbslwr_l
+# stub _mbslwr_s
+# stub _mbslwr_s_l
+@ cdecl _mbsnbcat (str str long)
+# stub _mbsnbcat_l
+# stub _mbsnbcat_s
+# stub _mbsnbcat_s_l
+@ cdecl _mbsnbcmp(str str long)
+# stub _mbsnbcmp_l
+@ cdecl _mbsnbcnt(ptr long)
+# stub _mbsnbcnt_l
+@ stub _mbsnbcoll #(str str long)
+# stub _mbsnbcoll_l
+@ cdecl _mbsnbcpy(ptr str long)
+# stub _mbsnbcpy_l
+@ cdecl _mbsnbcpy_s(ptr long str long)
+# stub _mbsnbcpy_s_l
+@ cdecl _mbsnbicmp(str str long)
+# stub _mbsnbicmp_l
+@ stub _mbsnbicoll #(str str long)
+# stub _mbsnbicoll_l
+@ cdecl _mbsnbset(str long long)
+# stub _mbsnbset_l
+# stub _mbsnbset_s
+# stub _mbsnbset_s_l
+@ cdecl _mbsncat(str str long)
+# stub _mbsncat_l
+# stub _mbsncat_s
+# stub _mbsncat_s_l
+@ cdecl _mbsnccnt(str long)
+# stub _mbsnccnt_l
+@ cdecl _mbsncmp(str str long)
+# stub _mbsncmp_l
+@ stub _mbsncoll #(str str long)
+# stub _mbsncoll_l
+@ cdecl _mbsncpy(str str long)
+# stub _mbsncpy_l
+# stub _mbsncpy_s
+# stub _mbsncpy_s_l
+@ cdecl _mbsnextc(str)
+# stub _mbsnextc_l
+@ cdecl _mbsnicmp(str str long)
+# stub _mbsnicmp_l
+@ stub _mbsnicoll #(str str long)
+# stub _mbsnicoll_l
+@ cdecl _mbsninc(str long)
+# stub _mbsninc_l
+# stub _mbsnlen
+# stub _mbsnlen_l
+@ cdecl _mbsnset(str long long)
+# stub _mbsnset_l
+# stub _mbsnset_s
+# stub _mbsnset_s_l
+@ cdecl _mbspbrk(str str)
+# stub _mbspbrk_l
+@ cdecl _mbsrchr(str long)
+# stub _mbsrchr_l
+@ cdecl _mbsrev(str)
+# stub _mbsrev_l
+@ cdecl _mbsset(str long)
+# stub _mbsset_l
+# stub _mbsset_s
+# stub _mbsset_s_l
+@ cdecl _mbsspn(str str)
+# stub _mbsspn_l
+@ cdecl _mbsspnp(str str)
+# stub _mbsspnp_l
+@ cdecl _mbsstr(str str)
+# stub _mbsstr_l
+@ cdecl _mbstok(str str)
+# stub _mbstok_l
+# stub _mbstok_s
+# stub _mbstok_s_l
+# stub _mbstowcs_l
+# stub _mbstowcs_s_l
+@ cdecl _mbstrlen(str)
+# stub _mbstrlen_l
+# stub _mbstrnlen
+# stub _mbstrnlen_l
+@ cdecl _mbsupr(str)
+# stub _mbsupr_l
+# stub _mbsupr_s
+# stub _mbsupr_s_l
+# stub _mbtowc_l
+@ cdecl _memccpy(ptr ptr long long)
+@ cdecl _memicmp(str str long)
+# stub _memicmp_l
+@ cdecl _mkdir(str)
+@ cdecl _mkgmtime(ptr)
+@ cdecl _mkgmtime32(ptr)
+@ cdecl _mkgmtime64(ptr)
+@ cdecl _mktemp(str)
+# stub _mktemp_s
+@ cdecl _mktime32(ptr)
+@ cdecl _mktime64(ptr)
+@ cdecl _msize(ptr)
+# stub _msize_debug
+@ cdecl _nextafter(double double)
+@ cdecl _onexit(ptr)
+@ varargs _open(str long)
+@ cdecl _open_osfhandle(long long)
+# stub _osplatform
+@ extern _osver _osver
+@ stub _outp #(long long)
+@ stub _outpd #(long long)
+@ stub _outpw #(long long)
+@ cdecl _pclose (ptr)
+@ extern _pctype _pctype
+@ extern _pgmptr _pgmptr
+@ cdecl _pipe (ptr long long)
+@ cdecl _popen (str str)
+# stub _printf_l
+# stub _printf_p
+# stub _printf_p_l
+# stub _printf_s_l
+@ cdecl _purecall()
+@ cdecl _putch(long)
+@ cdecl _putenv(str)
+# stub _putenv_s
+@ cdecl _putw(long ptr)
+# stub _putwch
+@ cdecl _putws(wstr)
+# extern _pwctype
+@ cdecl _read(long ptr long)
+# stub _realloc_dbg
+# stub _resetstkoflw
+@ cdecl _rmdir(str)
+@ cdecl _rmtmp()
+@ cdecl _rotl(long long)
+# stub _rotl64
+@ cdecl _rotr(long long)
+# stub _rotr64
+@ cdecl -arch=i386 _safe_fdiv()
+@ cdecl -arch=i386 _safe_fdivr()
+@ cdecl -arch=i386 _safe_fprem()
+@ cdecl -arch=i386 _safe_fprem1()
+@ cdecl _scalb(double long)
+# @ varargs _scanf_l(str ptr)
+# @ varargs _scanf_s_l(str ptr)
+# stub _scprintf
+# stub _scprintf_l
+# stub _scprintf_p_l
+# stub _scwprintf
+# stub _scwprintf_l
+# stub _scwprintf_p_l
+@ cdecl _searchenv(str str ptr)
+# stub _searchenv_s
+# stub _seh_longjmp_unwind4
+@ stdcall -i386 _seh_longjmp_unwind(ptr)
+# stub _set_SSE2_enable
+# stub _set_controlfp
+# stub _set_doserrno
+# stub _set_errno
+@ cdecl _set_error_mode(long)
+# stub _set_fileinfo
+# stub _set_fmode
+# stub _set_output_format
+@ cdecl _set_sbh_threshold(long)
+@ cdecl _seterrormode(long)
+@ cdecl -arch=i386,x86_64 -norelay _setjmp(ptr)
+@ cdecl -arch=i386 -norelay _setjmp3(ptr long)
+@ cdecl -arch=x86_64 -norelay _setjmpex(ptr ptr)
+@ cdecl _setmaxstdio(long)
+@ cdecl _setmbcp(long)
+@ cdecl _setmode(long long)
+@ stub _setsystime #(ptr long)
+@ cdecl _sleep(long)
+@ varargs _snprintf(ptr long str)
+# stub _snprintf_c
+# stub _snprintf_c_l
+# stub _snprintf_l
+# stub _snprintf_s
+# stub _snprintf_s_l
+# stub _snscanf
+# stub _snscanf_l
+# stub _snscanf_s
+# stub _snscanf_s_l
+@ varargs _snwprintf(ptr long wstr)
+# stub _snwprintf_l
+# stub _snwprintf_s
+# stub _snwprintf_s_l
+# stub _snwscanf
+# stub _snwscanf_l
+# stub _snwscanf_s
+# stub _snwscanf_s_l
+@ varargs _sopen(str long long)
+# stub _sopen_s
+@ varargs _spawnl(long str str)
+@ varargs _spawnle(long str str)
+@ varargs _spawnlp(long str str)
+@ varargs _spawnlpe(long str str)
+@ cdecl _spawnv(long str ptr)
+@ cdecl _spawnve(long str ptr ptr)
+@ cdecl _spawnvp(long str ptr)
+@ cdecl _spawnvpe(long str ptr ptr)
+@ cdecl _splitpath(str ptr ptr ptr ptr)
+# stub _splitpath_s
+# stub _sprintf_l
+# stub _sprintf_p_l
+# stub _sprintf_s_l
+# @ varargs _sscanf_l(str str ptr)
+# @ varargs _sscanf_s_l(str str ptr)
+@ cdecl _stat(str ptr)
+@ cdecl _stat64(str ptr)
+@ cdecl _stati64(str ptr)
+@ cdecl _statusfp()
+@ cdecl _strcmpi(str str)
+# stub _strcoll_l
+@ cdecl _strdate(ptr)
+# stub _strdate_s
+@ cdecl _strdup(str)
+# stub _strdup_dbg
+@ cdecl _strerror(long)
+# stub _strerror_s
+@ cdecl _stricmp(str str)
+# stub _stricmp_l
+@ cdecl _stricoll(str str)
+# stub _stricoll_l
+@ cdecl _strlwr(str)
+# stub _strlwr_l
+# stub _strlwr_s
+# stub _strlwr_s_l
+@ stub _strncoll #(str str long)
+# stub _strncoll_l
+@ cdecl _strnicmp(str str long)
+# stub _strnicmp_l
+@ stub _strnicoll #(str str long)
+# stub _strnicoll_l
+@ cdecl _strnset(str long long)
+# stub _strnset_s
+@ cdecl _strrev(str)
+@ cdecl _strset(str long)
+# stub _strset_s
+@ cdecl _strtime(ptr)
+# stub _strtime_s
+# @ cdecl _strtod_l(str ptr ptr)
+@ cdecl _strtoi64(str ptr long)
+# @ cdecl _strtoi64_l(str ptr long ptr)
+# stub _strtol_l
+@ cdecl _strtoui64(str ptr long) strtoull
+# @ cdecl _strtoui64_l(str ptr long ptr)
+# stub _strtoul_l
+@ cdecl _strupr(str)
+# stub _strupr_l
+# stub _strupr_s
+# stub _strupr_s_l
+# stub _strxfrm_l
+@ cdecl _swab(str str long)
+@ varargs _swprintf(ptr str) swprintf
+# stub _swprintf_c
+# stub _swprintf_c_l
+# stub _swprintf_p_l
+# stub _swprintf_s_l
+# @ varargs _swscanf_l(wstr wstr ptr)
+# @ varargs _swscanf_s_l(wstr wstr ptr)
+@ extern _sys_errlist
+@ extern _sys_nerr
+@ cdecl _tell(long)
+@ cdecl -ret64 _telli64(long)
+@ cdecl _tempnam(str str)
+# stub _tempnam_dbg
+@ cdecl _time32(ptr)
+@ cdecl _time64(ptr)
+@ extern _timezone
+@ cdecl _tolower(long)
+# stub _tolower_l
+@ cdecl _toupper(long)
+# stub _toupper_l
+# stub _towlower_l
+# stub _towupper_l
+@ extern _tzname
+@ cdecl _tzset()
+@ cdecl _ui64toa(long long ptr long)
+# stub _ui64toa_s
+@ cdecl _ui64tow(long long ptr long)
+# stub _ui64tow_s
+@ cdecl _ultoa(long ptr long)
+# stub _ultoa_s
+@ cdecl _ultow(long ptr long)
+# stub _ultow_s
+@ cdecl _umask(long)
+# stub _umask_s
+@ cdecl _ungetch(long)
+# stub _ungetwch
+@ cdecl _unlink(str)
+@ cdecl _unloaddll(long)
+@ cdecl _unlock(long)
+@ cdecl _utime32(str ptr)
+@ cdecl _utime64(str ptr)
+# stub _vcprintf
+# stub _vcprintf_l
+# stub _vcprintf_p
+# stub _vcprintf_p_l
+# stub _vcprintf_s
+# stub _vcprintf_s_l
+# stub _vcwprintf
+# stub _vcwprintf_l
+# stub _vcwprintf_p
+# stub _vcwprintf_p_l
+# stub _vcwprintf_s
+# stub _vcwprintf_s_l
+# stub _vfprintf_l
+# stub _vfprintf_p
+# stub _vfprintf_p_l
+# stub _vfprintf_s_l
+# stub _vfwprintf_l
+# stub _vfwprintf_p
+# stub _vfwprintf_p_l
+# stub _vfwprintf_s_l
+# stub _vprintf_l
+# stub _vprintf_p
+# stub _vprintf_p_l
+# stub _vprintf_s_l
+@ cdecl _utime(str ptr)
+# @ cdecl _vscprintf(str ptr)
+# stub _vscprintf_l
+# stub _vscprintf_p_l
+# @ cdecl _vscwprintf(wstr ptr)
+# stub _vscwprintf_l
+# stub _vscwprintf_p_l
+@ cdecl _vsnprintf(ptr long str ptr)
+@ cdecl _vsnprintf_c(ptr long str ptr) _vsnprintf
+# @ cdecl _vsnprintf_c_l(ptr long str ptr ptr) _vsnprintf_l
+# @ cdecl _vsnprintf_l(ptr long str ptr ptr)
+# @ cdecl _vsnprintf_s(ptr long long str ptr)
+# @ cdecl _vsnprintf_s_l(ptr long long str ptr ptr)
+@ cdecl _vsnwprintf(ptr long wstr ptr)
+# @ cdecl _vsnwprintf_l(ptr long wstr ptr ptr)
+# @ cdecl _vsnwprintf_s(ptr long long wstr ptr)
+# @ cdecl _vsnwprintf_s_l(ptr long long wstr ptr ptr)
+# stub _vsprintf_l
+# stub _vsprintf_p
+# stub _vsprintf_p_l
+# stub _vsprintf_s_l
+@ cdecl _vswprintf(ptr long wstr ptr) _vsnwprintf
+@ cdecl _vswprintf_c(ptr long wstr ptr) _vsnwprintf
+# @ cdecl _vswprintf_c_l(ptr long wstr ptr ptr) _vsnwprintf_l
+# @ cdecl _vswprintf_l(ptr long wstr ptr ptr) _vsnwprintf_l
+# @ cdecl _vswprintf_p_l(ptr long wstr ptr ptr) _vsnwprintf_l
+# @ cdecl _vswprintf_s_l(ptr long wstr ptr ptr)
+# stub _vwprintf_l
+# stub _vwprintf_p
+# stub _vwprintf_p_l
+# stub _vwprintf_s_l
+@ cdecl _waccess(wstr long)
+# stub _waccess_s
+@ cdecl _wasctime(ptr)
+# stub _wasctime_s
+# stub _wassert
+@ cdecl _wchdir(wstr)
+@ cdecl _wchmod(wstr long)
+@ extern _wcmdln _wcmdln
+@ cdecl _wcreat(wstr long)
+# stub _wcscoll_l
+@ cdecl _wcsdup(wstr)
+# stub _wcsdup_dbg
+# stub _wcserror
+# stub _wcserror_s
+# stub _wcsftime_l
+@ cdecl _wcsicmp(wstr wstr)
+# stub _wcsicmp_l
+@ cdecl _wcsicoll(wstr wstr)
+# stub _wcsicoll_l
+@ cdecl _wcslwr(wstr)
+# stub _wcslwr_l
+# stub _wcslwr_s
+# stub _wcslwr_s_l
+@ stub _wcsncoll #(wstr wstr long)
+# stub _wcsncoll_l
+@ cdecl _wcsnicmp(wstr wstr long)
+# stub _wcsnicmp_l
+@ stub _wcsnicoll #(wstr wstr long)
+# stub _wcsnicoll_l
+@ cdecl _wcsnset(wstr long long)
+# stub _wcsnset_s
+@ cdecl _wcsrev(wstr)
+@ cdecl _wcsset(wstr long)
+# stub _wcsset_s
+@ cdecl _wcstoi64(wstr ptr long)
+# @ cdecl _wcstoi64_l(wstr ptr long ptr)
+# stub _wcstol_l
+# stub _wcstombs_l
+# @ cdecl _wcstombs_s_l(ptr ptr long wstr long ptr)
+@ cdecl _wcstoui64(wstr ptr long)
+# @ cdecl _wcstoui64_l(wstr ptr long ptr)
+# stub _wcstoul_l
+@ cdecl _wcsupr(wstr)
+# stub _wcsupr_l
+@ cdecl _wcsupr_s(wstr long)
+# stub _wcsupr_s_l
+# stub _wcsxfrm_l
+@ cdecl _wctime(ptr)
+@ cdecl _wctime32(ptr)
+# stub _wctime32_s
+@ cdecl _wctime64(ptr)
+# stub _wctime64_s
+# stub _wctomb_l
+# stub _wctomb_s_l
+# stub _wctype
+@ extern _wenviron
+@ varargs _wexecl(wstr wstr)
+@ varargs _wexecle(wstr wstr)
+@ varargs _wexeclp(wstr wstr)
+@ varargs _wexeclpe(wstr wstr)
+@ cdecl _wexecv(wstr ptr)
+@ cdecl _wexecve(wstr ptr ptr)
+@ cdecl _wexecvp(wstr ptr)
+@ cdecl _wexecvpe(wstr ptr ptr)
+@ cdecl _wfdopen(long wstr)
+@ cdecl _wfindfirst(wstr ptr)
+# stub _wfindfirst64
+@ cdecl _wfindfirsti64(wstr ptr)
+@ cdecl _wfindnext(long ptr)
+# stub _wfindnext64
+@ cdecl _wfindnexti64(long ptr)
+@ cdecl _wfopen(wstr wstr)
+# @ cdecl _wfopen_s(ptr wstr wstr)
+@ cdecl _wfreopen(wstr wstr ptr)
+# stub _wfreopen_s
+@ cdecl _wfsopen(wstr wstr long)
+@ cdecl _wfullpath(ptr wstr long)
+# stub _wfullpath_dbg
+@ cdecl _wgetcwd(wstr long)
+@ cdecl _wgetdcwd(long wstr long)
+@ cdecl _wgetenv(wstr)
+# stub _wgetenv_s
+@ extern _winmajor
+@ extern _winminor
+# stub _winput_s
+@ extern _winver
+@ cdecl _wmakepath(wstr wstr wstr wstr wstr)
+# stub _wmakepath_s
+@ cdecl _wmkdir(wstr)
+@ cdecl _wmktemp(wstr)
+# stub _wmktemp_s
+@ varargs _wopen(wstr long)
+# stub _woutput_s
+@ stub _wperror #(wstr)
+@ extern _wpgmptr
+@ cdecl _wpopen (wstr wstr)
+# stub _wprintf_l
+# stub _wprintf_p
+# stub _wprintf_p_l
+# stub _wprintf_s_l
+@ cdecl _wputenv(wstr)
+# stub _wputenv_s
+@ cdecl _wremove(wstr)
+@ cdecl _wrename(wstr wstr)
+@ cdecl _write(long ptr long)
+@ cdecl _wrmdir(wstr)
+# @ varargs _wscanf_l(wstr ptr)
+# @ varargs _wscanf_s_l(wstr ptr)
+@ cdecl _wsearchenv(wstr wstr ptr)
+# stub _wsearchenv_s
+@ cdecl _wsetlocale(long wstr)
+@ varargs _wsopen (wstr long long)
+# stub _wsopen_s
+@ varargs _wspawnl(long wstr wstr)
+@ varargs _wspawnle(long wstr wstr)
+@ varargs _wspawnlp(long wstr wstr)
+@ varargs _wspawnlpe(long wstr wstr)
+@ cdecl _wspawnv(long wstr ptr)
+@ cdecl _wspawnve(long wstr ptr ptr)
+@ cdecl _wspawnvp(long wstr ptr)
+@ cdecl _wspawnvpe(long wstr ptr ptr)
+@ cdecl _wsplitpath(wstr ptr ptr ptr ptr)
+# @ cdecl _wsplitpath_s(wstr ptr long ptr long ptr long ptr long)
+@ cdecl _wstat(wstr ptr)
+@ cdecl _wstati64(wstr ptr)
+@ cdecl _wstat64(wstr ptr)
+@ cdecl _wstrdate(ptr)
+# stub _wstrdate_s
+@ cdecl _wstrtime(ptr)
+# stub _wstrtime_s
+@ cdecl _wsystem(wstr)
+@ cdecl _wtempnam(wstr wstr)
+# stub _wtempnam_dbg
+@ stub _wtmpnam #(ptr)
+# stub _wtmpnam_s
+# @ cdecl _wtof(wstr)
+# @ cdecl _wtof_l(wstr ptr)
+@ cdecl _wtoi(wstr)
+@ cdecl _wtoi64(wstr)
+# stub _wtoi64_l
+# stub _wtoi_l
+@ cdecl _wtol(wstr)
+# stub _wtol_l
+@ cdecl _wunlink(wstr)
+@ cdecl _wutime(wstr ptr)
+@ cdecl _wutime32(wstr ptr)
+@ cdecl _wutime64(wstr ptr)
+#@ cdecl _y0(double)
+#@ cdecl _y1(double)
+#@ cdecl _yn(long double )
+@ cdecl abort()
+@ cdecl abs(long)
+@ cdecl acos(double)
+@ cdecl asctime(ptr)
+# stub asctime_s
+@ cdecl asin(double)
+@ cdecl atan(double)
+@ cdecl atan2(double double)
+@ cdecl atexit(ptr)
+@ cdecl atof(str)
+@ cdecl atoi(str)
+@ cdecl atol(str)
+@ cdecl bsearch(ptr ptr long long ptr)
+# stub bsearch_s
+# @ cdecl btowc(long)
+@ cdecl calloc(long long)
+@ cdecl ceil(double)
+@ cdecl clearerr(ptr)
+# stub clearerr_s
+@ cdecl clock()
+@ cdecl cos(double)
+@ cdecl cosh(double)
+@ cdecl ctime(ptr)
+@ cdecl difftime(long long)
+@ cdecl div(long long)
+@ cdecl exit(long)
+@ cdecl exp(double)
+@ cdecl fabs(double)
+@ cdecl fclose(ptr)
+@ cdecl feof(ptr)
+@ cdecl ferror(ptr)
+@ cdecl fflush(ptr)
+@ cdecl fgetc(ptr)
+@ cdecl fgetpos(ptr ptr)
+@ cdecl fgets(ptr long ptr)
+@ cdecl fgetwc(ptr)
+@ cdecl fgetws(ptr long ptr)
+@ cdecl floor(double)
+@ cdecl fmod(double double)
+@ cdecl fopen(str str)
+# @ cdecl fopen_s(ptr str str)
+@ varargs fprintf(ptr str)
+# stub fprintf_s
+@ cdecl fputc(long ptr)
+@ cdecl fputs(str ptr)
+@ cdecl fputwc(long ptr)
+@ cdecl fputws(wstr ptr)
+@ cdecl fread(ptr long long ptr)
+@ cdecl free(ptr)
+@ cdecl freopen(str str ptr)
+# stub freopen_s
+@ cdecl frexp(double ptr)
+@ varargs fscanf(ptr str)
+# @ varargs fscanf_s(ptr str)
+@ cdecl fseek(ptr long long)
+@ cdecl fsetpos(ptr ptr)
+@ cdecl ftell(ptr)
+@ varargs fwprintf(ptr wstr)
+# stub fwprintf_s
+@ cdecl fwrite(ptr long long ptr)
+@ varargs fwscanf(ptr wstr)
+# @ varargs fwscanf_s(ptr wstr)
+@ cdecl getc(ptr)
+@ cdecl getchar()
+@ cdecl getenv(str)
+# stub getenv_s
+@ cdecl gets(str)
+@ cdecl getwc(ptr)
+@ cdecl getwchar()
+@ cdecl gmtime(ptr)
+@ cdecl is_wctype(long long)iswctype
+@ cdecl isalnum(long)
+@ cdecl isalpha(long)
+@ cdecl iscntrl(long)
+@ cdecl isdigit(long)
+@ cdecl isgraph(long)
+@ cdecl isleadbyte(long)
+@ cdecl islower(long)
+@ cdecl isprint(long)
+@ cdecl ispunct(long)
+@ cdecl isspace(long)
+@ cdecl isupper(long)
+@ cdecl iswalnum(long)
+@ cdecl iswalpha(long)
+@ cdecl iswascii(long)
+@ cdecl iswcntrl(long)
+@ cdecl iswctype(long long)
+@ cdecl iswdigit(long)
+@ cdecl iswgraph(long)
+@ cdecl iswlower(long)
+@ cdecl iswprint(long)
+@ cdecl iswpunct(long)
+@ cdecl iswspace(long)
+@ cdecl iswupper(long)
+@ cdecl iswxdigit(long)
+@ cdecl isxdigit(long)
+@ cdecl labs(long)
+@ cdecl ldexp(double long)
+@ cdecl ldiv(long long)
+@ cdecl localeconv()
+@ cdecl localtime(ptr)
+@ cdecl log(double)
+@ cdecl log10(double)
+@ cdecl -i386 longjmp(ptr long)
+@ cdecl malloc(long)
+@ cdecl mblen(ptr long)
+# stub mbrlen
+# stub mbrtowc
+# stub mbsdup_dbg
+# stub mbsrtowcs
+# stub mbsrtowcs_s
+@ cdecl mbstowcs(ptr str long)
+# stub mbstowcs_s
+@ cdecl mbtowc(wstr str long)
+@ cdecl memchr(ptr long long)
+@ cdecl memcmp(ptr ptr long)
+@ cdecl memcpy(ptr ptr long)
+# @ cdecl memcpy_s(ptr long ptr long) memmove_s
+@ cdecl memmove(ptr ptr long)
+# @ cdecl memmove_s(ptr long ptr long)
+@ cdecl memset(ptr long long)
+@ cdecl mktime(ptr)
+@ cdecl modf(double ptr)
+@ cdecl perror(str)
+@ cdecl pow(double double)
+@ varargs printf(str)
+# stub printf_s
+@ cdecl putc(long ptr)
+@ cdecl putchar(long)
+@ cdecl puts(str)
+@ cdecl putwc(long ptr) fputwc
+@ cdecl putwchar(long) _fputwchar
+@ cdecl qsort(ptr long long ptr)
+# stub qsort_s
+@ cdecl raise(long)
+@ cdecl rand()
+# @ cdecl rand_s(ptr)
+@ cdecl realloc(ptr long)
+@ cdecl remove(str)
+@ cdecl rename(str str)
+@ cdecl rewind(ptr)
+@ varargs scanf(str)
+# @ varargs scanf_s(str)
+@ cdecl setbuf(ptr ptr)
+@ cdecl -arch=x86_64 -norelay -private setjmp(ptr)
+@ cdecl setlocale(long str)
+@ cdecl setvbuf(ptr str long long)
+@ cdecl signal(long long)
+@ cdecl sin(double)
+@ cdecl sinh(double)
+@ varargs sprintf(ptr str)
+# @ varargs sprintf_s(ptr long str)
+@ cdecl sqrt(double)
+@ cdecl srand(long)
+@ varargs sscanf(str str)
+# @ varargs sscanf_s(str str)
+@ cdecl strcat(str str)
+@ cdecl strcat_s(str long str)
+@ cdecl strchr(str long)
+@ cdecl strcmp(str str)
+@ cdecl strcoll(str str)
+@ cdecl strcpy(ptr str)
+@ cdecl strcpy_s(ptr long str)
+@ cdecl strcspn(str str)
+@ cdecl strerror(long)
+# stub strerror_s
+@ cdecl strftime(str long str ptr)
+@ cdecl strlen(str)
+@ cdecl strncat(str str long)
+# stub strncat_s
+@ cdecl strncmp(str str long)
+@ cdecl strncpy(ptr str long)
+# @ cdecl strncpy_s(ptr long str long)
+@ cdecl strnlen(str long)
+@ cdecl strpbrk(str str)
+@ cdecl strrchr(str long)
+@ cdecl strspn(str str)
+@ cdecl strstr(str str)
+@ cdecl strtod(str ptr)
+@ cdecl strtok(str str)
+# @ cdecl strtok_s(ptr str ptr)
+@ cdecl strtol(str ptr long)
+@ cdecl strtoul(str ptr long)
+@ cdecl strxfrm(ptr str long)
+@ varargs swprintf(ptr wstr)
+# @ varargs swprintf_s(ptr long wstr)
+@ varargs swscanf(wstr wstr)
+# @ varargs swscanf_s(wstr wstr)
+@ cdecl system(str)
+@ cdecl tan(double)
+@ cdecl tanh(double)
+@ cdecl time(ptr)
+@ cdecl tmpfile()
+# stub tmpfile_s
+@ cdecl tmpnam(ptr)
+# stub tmpnam_s
+@ cdecl tolower(long)
+@ cdecl toupper(long)
+@ cdecl towlower(long)
+@ cdecl towupper(long)
+@ cdecl ungetc(long ptr)
+@ cdecl ungetwc(long ptr)
+# stub utime
+@ cdecl vfprintf(ptr str ptr)
+# stub vfprintf_s
+@ cdecl vfwprintf(ptr wstr ptr)
+# stub vfwprintf_s
+@ cdecl vprintf(str ptr)
+# stub vprintf_s
+# stub vsnprintf
+@ cdecl vsprintf(ptr str ptr)
+# @ cdecl vsprintf_s(ptr long str ptr)
+@ cdecl vswprintf(ptr wstr ptr)
+# @ cdecl vswprintf_s(ptr long wstr ptr)
+@ cdecl vwprintf(wstr ptr)
+# stub vwprintf_s
+# stub wcrtomb
+# stub wcrtomb_s
+@ cdecl wcscat(wstr wstr)
+# @ cdecl wcscat_s(wstr long wstr)
+@ cdecl wcschr(wstr long)
+@ cdecl wcscmp(wstr wstr)
+@ cdecl wcscoll(wstr wstr)
+@ cdecl wcscpy(ptr wstr)
+@ cdecl wcscpy_s(ptr long wstr)
+@ cdecl wcscspn(wstr wstr)
+@ cdecl wcsftime(ptr long wstr ptr)
+@ cdecl wcslen(wstr)
+@ cdecl wcsncat(wstr wstr long)
+# stub wcsncat_s
+@ cdecl wcsncmp(wstr wstr long)
+@ cdecl wcsncpy(ptr wstr long)
+@ cdecl wcsncpy_s(ptr long wstr long)
+# stub wcsnlen
+@ cdecl wcspbrk(wstr wstr)
+@ cdecl wcsrchr(wstr long)
+# stub wcsrtombs
+# stub wcsrtombs_s
+@ cdecl wcsspn(wstr wstr)
+@ cdecl wcsstr(wstr wstr)
+@ cdecl wcstod(wstr ptr)
+@ cdecl wcstok(wstr wstr)
+# stub wcstok_s
+@ cdecl wcstol(wstr ptr long)
+@ cdecl wcstombs(ptr ptr long)
+# @ cdecl wcstombs_s(ptr ptr long wstr long)
+@ cdecl wcstoul(wstr ptr long)
+@ stub wcsxfrm #(ptr wstr long)
+# stub wctob
+@ cdecl wctomb(ptr long)
+# stub wctomb_s
+@ varargs wprintf(wstr)
+# stub wprintf_s
+@ varargs wscanf(wstr)
+# @ varargs wscanf_s(wstr)
+
diff --git a/dll/win32/netevent/netevent.c b/dll/win32/netevent/netevent.c
new file mode 100644
index 00000000000..2534275adad
--- /dev/null
+++ b/dll/win32/netevent/netevent.c
@@ -0,0 +1,25 @@
+/*
+ * PROJECT: ReactOS Network Event Handler
+ * LICENSE: GPL - See COPYING in the top level directory
+ * FILE: dll/win32/netevent/netevent.c
+ * PURPOSE: Dummy main file
+ * COPYRIGHT: Eric Kohl
+ */
+
+#include
+
+BOOL
+WINAPI
+DllMain(IN HINSTANCE hinstDLL,
+ IN DWORD dwReason,
+ IN LPVOID lpvReserved)
+{
+ switch (dwReason)
+ {
+ case DLL_PROCESS_ATTACH:
+ DisableThreadLibraryCalls(hinstDLL);
+ break;
+ }
+
+ return TRUE;
+}
diff --git a/dll/win32/netevent/netevent.rbuild b/dll/win32/netevent/netevent.rbuild
new file mode 100644
index 00000000000..261bbeaf727
--- /dev/null
+++ b/dll/win32/netevent/netevent.rbuild
@@ -0,0 +1,8 @@
+
+
+ .
+ .
+ neteventmsg
+ netevent.c
+ netevt.rc
+
diff --git a/dll/win32/netevent/netevent.spec b/dll/win32/netevent/netevent.spec
new file mode 100644
index 00000000000..785ff690182
--- /dev/null
+++ b/dll/win32/netevent/netevent.spec
@@ -0,0 +1 @@
+# netevent.dll exports
diff --git a/dll/win32/netevent/netevt.rc b/dll/win32/netevent/netevt.rc
new file mode 100644
index 00000000000..78974220ec3
--- /dev/null
+++ b/dll/win32/netevent/netevt.rc
@@ -0,0 +1,9 @@
+#include
+
+#define REACTOS_VERSION_DLL
+#define REACTOS_STR_FILE_DESCRIPTION "ReactOS Network Event Handler\0"
+#define REACTOS_STR_INTERNAL_NAME "netevent\0"
+#define REACTOS_STR_ORIGINAL_FILENAME "netevent.dll\0"
+#include
+
+#include "netevent.rc"
diff --git a/dll/win32/odbc32/odbc32.rbuild b/dll/win32/odbc32/odbc32.rbuild
index 0539f4abfbe..30d8de7cea1 100644
--- a/dll/win32/odbc32/odbc32.rbuild
+++ b/dll/win32/odbc32/odbc32.rbuild
@@ -7,6 +7,7 @@
include/reactos/wine
wine
+ advapi32
proxyodbc.c
-
+
\ No newline at end of file
diff --git a/dll/win32/odbc32/odbc32.spec b/dll/win32/odbc32/odbc32.spec
index 8c5ac336b56..8e54e2bb3ec 100644
--- a/dll/win32/odbc32/odbc32.spec
+++ b/dll/win32/odbc32/odbc32.spec
@@ -86,43 +86,43 @@
86 stub ODBSetTryWaitValue
89 stub ODBCSharedPerfMon
90 stub ODBCSharedVSFlag
-106 stub SQLColAttributesW
-107 stub SQLConnectW
-108 stub SQLDescribeColW
-110 stub SQLErrorW
-111 stub SQLExecDirectW
-117 stub SQLGetCursorNameW
-119 stub SQLPrepareW
-121 stub SQLSetCursorNameW
-127 stub SQLColAttributeW
-132 stub SQLGetConnectAttrW
-133 stub SQLGetDescFieldW
-134 stub SQLGetDescRecW
-135 stub SQLGetDiagFieldW
-136 stub SQLGetDiagRecW
-138 stub SQLGetStmtAttrW
-139 stub SQLSetConnectAttrW
-140 stub SQLColumnsW
-141 stub SQLDriverConnectW
-142 stub SQLGetConnectOptionW
-145 stub SQLGetInfoW
-147 stub SQLGetTypeInfoW
-150 stub SQLSetConnectOptionW
-152 stub SQLSpecialColumnsW
-153 stub SQLStatisticsW
-154 stub SQLTablesW
-155 stub SQLBrowseConnectW
-156 stub SQLColumnPrivilegesW
-157 stub SQLDataSourcesW
-160 stub SQLForeignKeysW
-162 stub SQLNativeSqlW
-165 stub SQLPrimaryKeysW
-166 stub SQLProcedureColumnsW
-167 stub SQLProceduresW
-170 stub SQLTablePrivilegesW
-171 stub SQLDriversW
-173 stub SQLSetDescFieldW
-176 stub SQLSetStmtAttrW
+106 stdcall SQLColAttributesW(long long long ptr long ptr ptr)
+107 stdcall SQLConnectW(long wstr long wstr long wstr long)
+108 stdcall SQLDescribeColW(long long wstr long ptr ptr ptr ptr ptr)
+110 stdcall SQLErrorW(long long long wstr ptr wstr long ptr)
+111 stdcall SQLExecDirectW(long wstr long)
+117 stdcall SQLGetCursorNameW(long wstr long ptr)
+119 stdcall SQLPrepareW(long wstr long)
+121 stdcall SQLSetCursorNameW(long wstr long)
+127 stdcall SQLColAttributeW(long long long ptr long ptr ptr)
+132 stdcall SQLGetConnectAttrW(long long ptr long ptr)
+133 stdcall SQLGetDescFieldW(long long long ptr long ptr)
+134 stdcall SQLGetDescRecW(long long wstr long ptr ptr ptr ptr ptr ptr ptr)
+135 stdcall SQLGetDiagFieldW(long long long long ptr long ptr)
+136 stdcall SQLGetDiagRecW(long long long wstr ptr wstr long ptr)
+138 stdcall SQLGetStmtAttrW(long long ptr long ptr)
+139 stdcall SQLSetConnectAttrW(long long ptr long)
+140 stdcall SQLColumnsW(long wstr long wstr long wstr long wstr long)
+141 stdcall SQLDriverConnectW(long long wstr long wstr long wstr long)
+142 stdcall SQLGetConnectOptionW(long long ptr)
+145 stdcall SQLGetInfoW(long long ptr long ptr)
+147 stdcall SQLGetTypeInfoW(long long)
+150 stdcall SQLSetConnectOptionW(long long long)
+152 stdcall SQLSpecialColumnsW(long long wstr long wstr long wstr long long long)
+153 stdcall SQLStatisticsW(long wstr long wstr long wstr long long long)
+154 stdcall SQLTablesW(long wstr long wstr long wstr long wstr long)
+155 stdcall SQLBrowseConnectW(long wstr long wstr long ptr)
+156 stdcall SQLColumnPrivilegesW(long wstr long wstr long wstr long wstr long)
+157 stdcall SQLDataSourcesW(long long wstr long ptr wstr long ptr)
+160 stdcall SQLForeignKeysW(long wstr long wstr long wstr long wstr long wstr long wstr long)
+162 stdcall SQLNativeSqlW(long wstr long wstr long ptr)
+165 stdcall SQLPrimaryKeysW(long wstr long wstr long wstr long)
+166 stdcall SQLProcedureColumnsW(long wstr long wstr long wstr long wstr long)
+167 stdcall SQLProceduresW(long wstr long wstr long wstr long)
+170 stdcall SQLTablePrivilegesW(long wstr long wstr long wstr long)
+171 stdcall SQLDriversW(long long wstr long ptr wstr long ptr)
+173 stdcall SQLSetDescFieldW(long long long ptr long)
+176 stdcall SQLSetStmtAttrW(long long ptr long)
206 stub SQLColAttributesA
207 stub SQLConnectA
208 stub SQLDescribeColA
diff --git a/dll/win32/odbc32/odbc32_ros.diff b/dll/win32/odbc32/odbc32_ros.diff
new file mode 100644
index 00000000000..f39e563ce62
--- /dev/null
+++ b/dll/win32/odbc32/odbc32_ros.diff
@@ -0,0 +1,395 @@
+Index: proxyodbc.c
+===================================================================
+--- proxyodbc.c (Revision 41027)
++++ proxyodbc.c (Arbeitskopie)
+@@ -733,8 +733,8 @@
+ */
+ SQLRETURN WINAPI SQLBindCol(SQLHSTMT StatementHandle,
+ SQLUSMALLINT ColumnNumber, SQLSMALLINT TargetType,
+- SQLPOINTER TargetValue, SQLINTEGER BufferLength,
+- SQLINTEGER *StrLen_or_Ind)
++ SQLPOINTER TargetValue, SQLLEN BufferLength,
++ SQLLEN *StrLen_or_Ind)
+ {
+ TRACE("\n");
+
+@@ -756,9 +756,9 @@
+ */
+ SQLRETURN WINAPI SQLBindParam(SQLHSTMT StatementHandle,
+ SQLUSMALLINT ParameterNumber, SQLSMALLINT ValueType,
+- SQLSMALLINT ParameterType, SQLUINTEGER LengthPrecision,
++ SQLSMALLINT ParameterType, SQLULEN LengthPrecision,
+ SQLSMALLINT ParameterScale, SQLPOINTER ParameterValue,
+- SQLINTEGER *StrLen_or_Ind)
++ SQLLEN *StrLen_or_Ind)
+ {
+ TRACE("\n");
+
+@@ -926,7 +926,7 @@
+ SQLRETURN WINAPI SQLDescribeCol(SQLHSTMT StatementHandle,
+ SQLUSMALLINT ColumnNumber, SQLCHAR *ColumnName,
+ SQLSMALLINT BufferLength, SQLSMALLINT *NameLength,
+- SQLSMALLINT *DataType, SQLUINTEGER *ColumnSize,
++ SQLSMALLINT *DataType, SQLULEN *ColumnSize,
+ SQLSMALLINT *DecimalDigits, SQLSMALLINT *Nullable)
+ {
+ TRACE("\n");
+@@ -1040,7 +1040,7 @@
+ /*************************************************************************
+ * SQLFetchScroll [ODBC32.030]
+ */
+-SQLRETURN WINAPI SQLFetchScroll(SQLHSTMT StatementHandle, SQLSMALLINT FetchOrientation, SQLINTEGER FetchOffset)
++SQLRETURN WINAPI SQLFetchScroll(SQLHSTMT StatementHandle, SQLSMALLINT FetchOrientation, SQLLEN FetchOffset)
+ {
+ TRACE("\n");
+
+@@ -1177,8 +1177,8 @@
+ */
+ SQLRETURN WINAPI SQLGetData(SQLHSTMT StatementHandle,
+ SQLUSMALLINT ColumnNumber, SQLSMALLINT TargetType,
+- SQLPOINTER TargetValue, SQLINTEGER BufferLength,
+- SQLINTEGER *StrLen_or_Ind)
++ SQLPOINTER TargetValue, SQLLEN BufferLength,
++ SQLLEN *StrLen_or_Ind)
+ {
+ TRACE("\n");
+
+@@ -1217,7 +1217,7 @@
+ SQLSMALLINT RecNumber, SQLCHAR *Name,
+ SQLSMALLINT BufferLength, SQLSMALLINT *StringLength,
+ SQLSMALLINT *Type, SQLSMALLINT *SubType,
+- SQLINTEGER *Length, SQLSMALLINT *Precision,
++ SQLLEN *Length, SQLSMALLINT *Precision,
+ SQLSMALLINT *Scale, SQLSMALLINT *Nullable)
+ {
+ TRACE("\n");
+@@ -1413,7 +1413,7 @@
+ /*************************************************************************
+ * SQLPutData [ODBC32.049]
+ */
+-SQLRETURN WINAPI SQLPutData(SQLHSTMT StatementHandle, SQLPOINTER Data, SQLINTEGER StrLen_or_Ind)
++SQLRETURN WINAPI SQLPutData(SQLHSTMT StatementHandle, SQLPOINTER Data, SQLLEN StrLen_or_Ind)
+ {
+ TRACE("\n");
+
+@@ -1428,7 +1428,7 @@
+ /*************************************************************************
+ * SQLRowCount [ODBC32.020]
+ */
+-SQLRETURN WINAPI SQLRowCount(SQLHSTMT StatementHandle, SQLINTEGER *RowCount)
++SQLRETURN WINAPI SQLRowCount(SQLHSTMT StatementHandle, SQLLEN *RowCount)
+ {
+ TRACE("\n");
+
+@@ -1459,7 +1459,7 @@
+ /*************************************************************************
+ * SQLSetConnectOption [ODBC32.050]
+ */
+-SQLRETURN WINAPI SQLSetConnectOption(SQLHDBC ConnectionHandle, SQLUSMALLINT Option, SQLUINTEGER Value)
++SQLRETURN WINAPI SQLSetConnectOption(SQLHDBC ConnectionHandle, SQLUSMALLINT Option, SQLULEN Value)
+ {
+ TRACE("\n");
+
+@@ -1508,10 +1508,10 @@
+ */
+ SQLRETURN WINAPI SQLSetDescRec(SQLHDESC DescriptorHandle,
+ SQLSMALLINT RecNumber, SQLSMALLINT Type,
+- SQLSMALLINT SubType, SQLINTEGER Length,
++ SQLSMALLINT SubType, SQLLEN Length,
+ SQLSMALLINT Precision, SQLSMALLINT Scale,
+- SQLPOINTER Data, SQLINTEGER *StringLength,
+- SQLINTEGER *Indicator)
++ SQLPOINTER Data, SQLLEN *StringLength,
++ SQLLEN *Indicator)
+ {
+ TRACE("\n");
+
+@@ -1546,9 +1546,9 @@
+ */
+ SQLRETURN WINAPI SQLSetParam(SQLHSTMT StatementHandle,
+ SQLUSMALLINT ParameterNumber, SQLSMALLINT ValueType,
+- SQLSMALLINT ParameterType, SQLUINTEGER LengthPrecision,
++ SQLSMALLINT ParameterType, SQLULEN LengthPrecision,
+ SQLSMALLINT ParameterScale, SQLPOINTER ParameterValue,
+- SQLINTEGER *StrLen_or_Ind)
++ SQLLEN *StrLen_or_Ind)
+ {
+ TRACE("\n");
+
+@@ -1581,7 +1581,7 @@
+ /*************************************************************************
+ * SQLSetStmtOption [ODBC32.051]
+ */
+-SQLRETURN WINAPI SQLSetStmtOption(SQLHSTMT StatementHandle, SQLUSMALLINT Option, SQLUINTEGER Value)
++SQLRETURN WINAPI SQLSetStmtOption(SQLHSTMT StatementHandle, SQLUSMALLINT Option, SQLULEN Value)
+ {
+ TRACE("\n");
+
+@@ -1717,7 +1717,7 @@
+ SQLPOINTER rgbDesc,
+ SQLSMALLINT cbDescMax,
+ SQLSMALLINT *pcbDesc,
+- SQLINTEGER *pfDesc)
++ SQLLEN *pfDesc)
+ {
+ TRACE("\n");
+
+@@ -1761,7 +1761,7 @@
+ SQLHSTMT hstmt,
+ SQLUSMALLINT ipar,
+ SQLSMALLINT *pfSqlType,
+- SQLUINTEGER *pcbParamDef,
++ SQLULEN *pcbParamDef,
+ SQLSMALLINT *pibScale,
+ SQLSMALLINT *pfNullable)
+ {
+@@ -2039,11 +2039,11 @@
+ SQLSMALLINT fParamType,
+ SQLSMALLINT fCType,
+ SQLSMALLINT fSqlType,
+- SQLUINTEGER cbColDef,
++ SQLULEN cbColDef,
+ SQLSMALLINT ibScale,
+ SQLPOINTER rgbValue,
+- SQLINTEGER cbValueMax,
+- SQLINTEGER *pcbValue)
++ SQLLEN cbValueMax,
++ SQLLEN *pcbValue)
+ {
+ TRACE("\n");
+
+@@ -2086,7 +2086,7 @@
+ SQLRETURN WINAPI SQLSetScrollOptions(
+ SQLHSTMT statement_handle,
+ SQLUSMALLINT f_concurrency,
+- SQLINTEGER crow_keyset,
++ SQLLEN crow_keyset,
+ SQLUSMALLINT crow_rowset )
+ {
+ TRACE("\n");
+@@ -2138,7 +2138,7 @@
+ SQLPOINTER rgbDesc,
+ SQLSMALLINT cbDescMax,
+ SQLSMALLINT *pcbDesc,
+- SQLINTEGER *pfDesc)
++ SQLLEN *pfDesc)
+ {
+ SQLRETURN iResult;
+
+@@ -2200,9 +2200,9 @@
+ * SQLDescribeColW [ODBC32.108]
+ */
+ SQLRETURN WINAPI SQLDescribeColW(SQLHSTMT StatementHandle,
+- SQLUSMALLINT ColumnNumber, WCHAR *ColumnName,
++ SQLUSMALLINT ColumnNumber, SQLWCHAR *ColumnName,
+ SQLSMALLINT BufferLength, SQLSMALLINT *NameLength,
+- SQLSMALLINT *DataType, SQLUINTEGER *ColumnSize,
++ SQLSMALLINT *DataType, SQLULEN *ColumnSize,
+ SQLSMALLINT *DecimalDigits, SQLSMALLINT *Nullable)
+ {
+ SQLRETURN iResult;
+@@ -2378,10 +2378,10 @@
+ * SQLGetDescRecW [ODBC32.134]
+ */
+ SQLRETURN WINAPI SQLGetDescRecW(SQLHDESC DescriptorHandle,
+- SQLSMALLINT RecNumber, WCHAR *Name,
++ SQLSMALLINT RecNumber, SQLWCHAR *Name,
+ SQLSMALLINT BufferLength, SQLSMALLINT *StringLength,
+ SQLSMALLINT *Type, SQLSMALLINT *SubType,
+- SQLINTEGER *Length, SQLSMALLINT *Precision,
++ SQLLEN *Length, SQLSMALLINT *Precision,
+ SQLSMALLINT *Scale, SQLSMALLINT *Nullable)
+ {
+ TRACE("\n");
+@@ -2573,7 +2573,7 @@
+ /*************************************************************************
+ * SQLSetConnectOptionW [ODBC32.150]
+ */
+-SQLRETURN WINAPI SQLSetConnectOptionW(SQLHDBC ConnectionHandle, SQLUSMALLINT Option, SQLUINTEGER Value)
++SQLRETURN WINAPI SQLSetConnectOptionW(SQLHDBC ConnectionHandle, SQLUSMALLINT Option, SQLULEN Value)
+ {
+ TRACE("\n");
+
+@@ -2588,9 +2588,9 @@
+ * SQLSpecialColumnsW [ODBC32.152]
+ */
+ SQLRETURN WINAPI SQLSpecialColumnsW(SQLHSTMT StatementHandle,
+- SQLUSMALLINT IdentifierType, SQLCHAR *CatalogName,
+- SQLSMALLINT NameLength1, SQLCHAR *SchemaName,
+- SQLSMALLINT NameLength2, SQLCHAR *TableName,
++ SQLUSMALLINT IdentifierType, SQLWCHAR *CatalogName,
++ SQLSMALLINT NameLength1, SQLWCHAR *SchemaName,
++ SQLSMALLINT NameLength2, SQLWCHAR *TableName,
+ SQLSMALLINT NameLength3, SQLUSMALLINT Scope,
+ SQLUSMALLINT Nullable)
+ {
+@@ -2607,9 +2607,9 @@
+ * SQLStatisticsW [ODBC32.153]
+ */
+ SQLRETURN WINAPI SQLStatisticsW(SQLHSTMT StatementHandle,
+- SQLCHAR *CatalogName, SQLSMALLINT NameLength1,
+- SQLCHAR *SchemaName, SQLSMALLINT NameLength2,
+- SQLCHAR *TableName, SQLSMALLINT NameLength3,
++ SQLWCHAR *CatalogName, SQLSMALLINT NameLength1,
++ SQLWCHAR *SchemaName, SQLSMALLINT NameLength2,
++ SQLWCHAR *TableName, SQLSMALLINT NameLength3,
+ SQLUSMALLINT Unique, SQLUSMALLINT Reserved)
+ {
+ TRACE("\n");
+@@ -2626,10 +2626,10 @@
+ * SQLTablesW [ODBC32.154]
+ */
+ SQLRETURN WINAPI SQLTablesW(SQLHSTMT StatementHandle,
+- SQLCHAR *CatalogName, SQLSMALLINT NameLength1,
+- SQLCHAR *SchemaName, SQLSMALLINT NameLength2,
+- SQLCHAR *TableName, SQLSMALLINT NameLength3,
+- SQLCHAR *TableType, SQLSMALLINT NameLength4)
++ SQLWCHAR *CatalogName, SQLSMALLINT NameLength1,
++ SQLWCHAR *SchemaName, SQLSMALLINT NameLength2,
++ SQLWCHAR *TableName, SQLSMALLINT NameLength3,
++ SQLWCHAR *TableType, SQLSMALLINT NameLength4)
+ {
+ TRACE("\n");
+
+@@ -2646,9 +2646,9 @@
+ */
+ SQLRETURN WINAPI SQLBrowseConnectW(
+ SQLHDBC hdbc,
+- SQLCHAR *szConnStrIn,
++ SQLWCHAR *szConnStrIn,
+ SQLSMALLINT cbConnStrIn,
+- SQLCHAR *szConnStrOut,
++ SQLWCHAR *szConnStrOut,
+ SQLSMALLINT cbConnStrOutMax,
+ SQLSMALLINT *pcbConnStrOut)
+ {
+@@ -2666,13 +2666,13 @@
+ */
+ SQLRETURN WINAPI SQLColumnPrivilegesW(
+ SQLHSTMT hstmt,
+- SQLCHAR *szCatalogName,
++ SQLWCHAR *szCatalogName,
+ SQLSMALLINT cbCatalogName,
+- SQLCHAR *szSchemaName,
++ SQLWCHAR *szSchemaName,
+ SQLSMALLINT cbSchemaName,
+- SQLCHAR *szTableName,
++ SQLWCHAR *szTableName,
+ SQLSMALLINT cbTableName,
+- SQLCHAR *szColumnName,
++ SQLWCHAR *szColumnName,
+ SQLSMALLINT cbColumnName)
+ {
+ TRACE("\n");
+@@ -2727,17 +2727,17 @@
+ */
+ SQLRETURN WINAPI SQLForeignKeysW(
+ SQLHSTMT hstmt,
+- SQLCHAR *szPkCatalogName,
++ SQLWCHAR *szPkCatalogName,
+ SQLSMALLINT cbPkCatalogName,
+- SQLCHAR *szPkSchemaName,
++ SQLWCHAR *szPkSchemaName,
+ SQLSMALLINT cbPkSchemaName,
+- SQLCHAR *szPkTableName,
++ SQLWCHAR *szPkTableName,
+ SQLSMALLINT cbPkTableName,
+- SQLCHAR *szFkCatalogName,
++ SQLWCHAR *szFkCatalogName,
+ SQLSMALLINT cbFkCatalogName,
+- SQLCHAR *szFkSchemaName,
++ SQLWCHAR *szFkSchemaName,
+ SQLSMALLINT cbFkSchemaName,
+- SQLCHAR *szFkTableName,
++ SQLWCHAR *szFkTableName,
+ SQLSMALLINT cbFkTableName)
+ {
+ TRACE("\n");
+@@ -2756,9 +2756,9 @@
+ */
+ SQLRETURN WINAPI SQLNativeSqlW(
+ SQLHDBC hdbc,
+- SQLCHAR *szSqlStrIn,
++ SQLWCHAR *szSqlStrIn,
+ SQLINTEGER cbSqlStrIn,
+- SQLCHAR *szSqlStr,
++ SQLWCHAR *szSqlStr,
+ SQLINTEGER cbSqlStrMax,
+ SQLINTEGER *pcbSqlStr)
+ {
+@@ -2776,11 +2776,11 @@
+ */
+ SQLRETURN WINAPI SQLPrimaryKeysW(
+ SQLHSTMT hstmt,
+- SQLCHAR *szCatalogName,
++ SQLWCHAR *szCatalogName,
+ SQLSMALLINT cbCatalogName,
+- SQLCHAR *szSchemaName,
++ SQLWCHAR *szSchemaName,
+ SQLSMALLINT cbSchemaName,
+- SQLCHAR *szTableName,
++ SQLWCHAR *szTableName,
+ SQLSMALLINT cbTableName)
+ {
+ TRACE("\n");
+@@ -2798,13 +2798,13 @@
+ */
+ SQLRETURN WINAPI SQLProcedureColumnsW(
+ SQLHSTMT hstmt,
+- SQLCHAR *szCatalogName,
++ SQLWCHAR *szCatalogName,
+ SQLSMALLINT cbCatalogName,
+- SQLCHAR *szSchemaName,
++ SQLWCHAR *szSchemaName,
+ SQLSMALLINT cbSchemaName,
+- SQLCHAR *szProcName,
++ SQLWCHAR *szProcName,
+ SQLSMALLINT cbProcName,
+- SQLCHAR *szColumnName,
++ SQLWCHAR *szColumnName,
+ SQLSMALLINT cbColumnName)
+ {
+ TRACE("\n");
+@@ -2822,11 +2822,11 @@
+ */
+ SQLRETURN WINAPI SQLProceduresW(
+ SQLHSTMT hstmt,
+- SQLCHAR *szCatalogName,
++ SQLWCHAR *szCatalogName,
+ SQLSMALLINT cbCatalogName,
+- SQLCHAR *szSchemaName,
++ SQLWCHAR *szSchemaName,
+ SQLSMALLINT cbSchemaName,
+- SQLCHAR *szProcName,
++ SQLWCHAR *szProcName,
+ SQLSMALLINT cbProcName)
+ {
+ TRACE("\n");
+@@ -2844,11 +2844,11 @@
+ */
+ SQLRETURN WINAPI SQLTablePrivilegesW(
+ SQLHSTMT hstmt,
+- SQLCHAR *szCatalogName,
++ SQLWCHAR *szCatalogName,
+ SQLSMALLINT cbCatalogName,
+- SQLCHAR *szSchemaName,
++ SQLWCHAR *szSchemaName,
+ SQLSMALLINT cbSchemaName,
+- SQLCHAR *szTableName,
++ SQLWCHAR *szTableName,
+ SQLSMALLINT cbTableName)
+ {
+ TRACE("\n");
+@@ -2867,10 +2867,10 @@
+ SQLRETURN WINAPI SQLDriversW(
+ SQLHENV henv,
+ SQLUSMALLINT fDirection,
+- SQLCHAR *szDriverDesc,
++ SQLWCHAR *szDriverDesc,
+ SQLSMALLINT cbDriverDescMax,
+ SQLSMALLINT *pcbDriverDesc,
+- SQLCHAR *szDriverAttributes,
++ SQLWCHAR *szDriverAttributes,
+ SQLSMALLINT cbDriverAttrMax,
+ SQLSMALLINT *pcbDriverAttr)
+ {
diff --git a/dll/win32/odbc32/proxyodbc.c b/dll/win32/odbc32/proxyodbc.c
index 58d587082f5..a5d5615b54a 100644
--- a/dll/win32/odbc32/proxyodbc.c
+++ b/dll/win32/odbc32/proxyodbc.c
@@ -18,8 +18,8 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*
* NOTES:
- * Proxy ODBC driver manager. This manager delegates all ODBC
- * calls to a real ODBC driver manager named by the environment
+ * Proxy ODBC driver manager. This manager delegates all ODBC
+ * calls to a real ODBC driver manager named by the environment
* variable LIB_ODBC_DRIVER_MANAGER, or to libodbc.so if the
* variable is not set.
*
@@ -36,15 +36,18 @@
#include "windef.h"
#include "winbase.h"
-#include "wine/debug.h"
-//#include "wine/library.h"
-
-#undef TRACE_ON
+#include "winreg.h"
#include "sql.h"
#include "sqltypes.h"
#include "sqlext.h"
+#undef TRACE_ON
+
+#include "wine/debug.h"
+#include "wine/library.h"
+#include "wine/unicode.h"
+
#include "proxyodbc.h"
static BOOL ODBC_LoadDriverManager(void);
@@ -54,84 +57,84 @@ WINE_DEFAULT_DEBUG_CHANNEL(odbc);
static const DM_FUNC template_func[] =
{
- /* 00 */ { SQL_API_SQLALLOCCONNECT, "SQLAllocConnect", SQLAllocConnect, NULL },
- /* 01 */ { SQL_API_SQLALLOCENV, "SQLAllocEnv", SQLAllocEnv, NULL },
- /* 02 */ { SQL_API_SQLALLOCHANDLE, "SQLAllocHandle", SQLAllocHandle, NULL },
- /* 03 */ { SQL_API_SQLALLOCSTMT, "SQLAllocStmt", SQLAllocStmt, NULL },
- /* 04 */ { SQL_API_SQLALLOCHANDLESTD, "SQLAllocHandleStd", SQLAllocHandleStd, NULL },
- /* 05 */ { SQL_API_SQLBINDCOL, "SQLBindCol", SQLBindCol, NULL },
- /* 06 */ { SQL_API_SQLBINDPARAM, "SQLBindParam", SQLBindParam, NULL },
- /* 07 */ { SQL_API_SQLBINDPARAMETER, "SQLBindParameter", SQLBindParameter, NULL },
- /* 08 */ { SQL_API_SQLBROWSECONNECT, "SQLBrowseConnect", SQLBrowseConnect, NULL },
- /* 09 */ { SQL_API_SQLBULKOPERATIONS, "SQLBulkOperations", SQLBulkOperations, NULL },
- /* 10 */ { SQL_API_SQLCANCEL, "SQLCancel", SQLCancel, NULL },
- /* 11 */ { SQL_API_SQLCLOSECURSOR, "SQLCloseCursor", SQLCloseCursor, NULL },
- /* 12 */ { SQL_API_SQLCOLATTRIBUTE, "SQLColAttribute", SQLColAttribute, NULL },
- /* 13 */ { SQL_API_SQLCOLATTRIBUTES, "SQLColAttributes", SQLColAttributes, NULL },
- /* 14 */ { SQL_API_SQLCOLUMNPRIVILEGES, "SQLColumnPrivileges", SQLColumnPrivileges, NULL },
- /* 15 */ { SQL_API_SQLCOLUMNS, "SQLColumns", SQLColumns, NULL },
- /* 16 */ { SQL_API_SQLCONNECT, "SQLConnect", SQLConnect, NULL },
- /* 17 */ { SQL_API_SQLCOPYDESC, "SQLCopyDesc", SQLCopyDesc, NULL },
- /* 18 */ { SQL_API_SQLDATASOURCES, "SQLDataSources", SQLDataSources, NULL },
- /* 19 */ { SQL_API_SQLDESCRIBECOL, "SQLDescribeCol", SQLDescribeCol, NULL },
- /* 20 */ { SQL_API_SQLDESCRIBEPARAM, "SQLDescribeParam", SQLDescribeParam, NULL },
- /* 21 */ { SQL_API_SQLDISCONNECT, "SQLDisconnect", SQLDisconnect, NULL },
- /* 22 */ { SQL_API_SQLDRIVERCONNECT, "SQLDriverConnect", SQLDriverConnect, NULL },
- /* 23 */ { SQL_API_SQLDRIVERS, "SQLDrivers", SQLDrivers, NULL },
- /* 24 */ { SQL_API_SQLENDTRAN, "SQLEndTran", SQLEndTran, NULL },
- /* 25 */ { SQL_API_SQLERROR, "SQLError", SQLError, NULL },
- /* 26 */ { SQL_API_SQLEXECDIRECT, "SQLExecDirect", SQLExecDirect, NULL },
- /* 27 */ { SQL_API_SQLEXECUTE, "SQLExecute", SQLExecute, NULL },
- /* 28 */ { SQL_API_SQLEXTENDEDFETCH, "SQLExtendedFetch", SQLExtendedFetch, NULL },
- /* 29 */ { SQL_API_SQLFETCH, "SQLFetch", SQLFetch, NULL },
- /* 30 */ { SQL_API_SQLFETCHSCROLL, "SQLFetchScroll", SQLFetchScroll, NULL },
- /* 31 */ { SQL_API_SQLFOREIGNKEYS, "SQLForeignKeys", SQLForeignKeys, NULL },
- /* 32 */ { SQL_API_SQLFREEENV, "SQLFreeEnv", SQLFreeEnv, NULL },
- /* 33 */ { SQL_API_SQLFREEHANDLE, "SQLFreeHandle", SQLFreeHandle, NULL },
- /* 34 */ { SQL_API_SQLFREESTMT, "SQLFreeStmt", SQLFreeStmt, NULL },
- /* 35 */ { SQL_API_SQLFREECONNECT, "SQLFreeConnect", SQLFreeConnect, NULL },
- /* 36 */ { SQL_API_SQLGETCONNECTATTR, "SQLGetConnectAttr", SQLGetConnectAttr, NULL },
- /* 37 */ { SQL_API_SQLGETCONNECTOPTION, "SQLGetConnectOption", SQLGetConnectOption, NULL },
- /* 38 */ { SQL_API_SQLGETCURSORNAME, "SQLGetCursorName", SQLGetCursorName, NULL },
- /* 39 */ { SQL_API_SQLGETDATA, "SQLGetData", SQLGetData, NULL },
- /* 40 */ { SQL_API_SQLGETDESCFIELD, "SQLGetDescField", SQLGetDescField, NULL },
- /* 41 */ { SQL_API_SQLGETDESCREC, "SQLGetDescRec", SQLGetDescRec, NULL },
- /* 42 */ { SQL_API_SQLGETDIAGFIELD, "SQLGetDiagField", SQLGetDiagField, NULL },
- /* 43 */ { SQL_API_SQLGETENVATTR, "SQLGetEnvAttr", SQLGetEnvAttr, NULL },
- /* 44 */ { SQL_API_SQLGETFUNCTIONS, "SQLGetFunctions", SQLGetFunctions, NULL },
- /* 45 */ { SQL_API_SQLGETINFO, "SQLGetInfo", SQLGetInfo, NULL },
- /* 46 */ { SQL_API_SQLGETSTMTATTR, "SQLGetStmtAttr", SQLGetStmtAttr, NULL },
- /* 47 */ { SQL_API_SQLGETSTMTOPTION, "SQLGetStmtOption", SQLGetStmtOption, NULL },
- /* 48 */ { SQL_API_SQLGETTYPEINFO, "SQLGetTypeInfo", SQLGetTypeInfo, NULL },
- /* 49 */ { SQL_API_SQLMORERESULTS, "SQLMoreResults", SQLMoreResults, NULL },
- /* 50 */ { SQL_API_SQLNATIVESQL, "SQLNativeSql", SQLNativeSql, NULL },
- /* 51 */ { SQL_API_SQLNUMPARAMS, "SQLNumParams", SQLNumParams, NULL },
- /* 52 */ { SQL_API_SQLNUMRESULTCOLS, "SQLNumResultCols", SQLNumResultCols, NULL },
- /* 53 */ { SQL_API_SQLPARAMDATA, "SQLParamData", SQLParamData, NULL },
- /* 54 */ { SQL_API_SQLPARAMOPTIONS, "SQLParamOptions", SQLParamOptions, NULL },
- /* 55 */ { SQL_API_SQLPREPARE, "SQLPrepare", SQLPrepare, NULL },
- /* 56 */ { SQL_API_SQLPRIMARYKEYS, "SQLPrimaryKeys", SQLPrimaryKeys, NULL },
- /* 57 */ { SQL_API_SQLPROCEDURECOLUMNS, "SQLProcedureColumns", SQLProcedureColumns, NULL },
- /* 58 */ { SQL_API_SQLPROCEDURES, "SQLProcedures", SQLProcedures, NULL },
- /* 59 */ { SQL_API_SQLPUTDATA, "SQLPutData", SQLPutData, NULL },
- /* 60 */ { SQL_API_SQLROWCOUNT, "SQLRowCount", SQLRowCount, NULL },
- /* 61 */ { SQL_API_SQLSETCONNECTATTR, "SQLSetConnectAttr", SQLSetConnectAttr, NULL },
- /* 62 */ { SQL_API_SQLSETCONNECTOPTION, "SQLSetConnectOption", SQLSetConnectOption, NULL },
- /* 63 */ { SQL_API_SQLSETCURSORNAME, "SQLSetCursorName", SQLSetCursorName, NULL },
- /* 64 */ { SQL_API_SQLSETDESCFIELD, "SQLSetDescField", SQLSetDescField, NULL },
- /* 65 */ { SQL_API_SQLSETDESCREC, "SQLSetDescRec", SQLSetDescRec, NULL },
- /* 66 */ { SQL_API_SQLSETENVATTR, "SQLSetEnvAttr", SQLSetEnvAttr, NULL },
- /* 67 */ { SQL_API_SQLSETPARAM, "SQLSetParam", SQLSetParam, NULL },
- /* 68 */ { SQL_API_SQLSETPOS, "SQLSetPos", SQLSetPos, NULL },
- /* 69 */ { SQL_API_SQLSETSCROLLOPTIONS, "SQLSetScrollOptions", SQLSetScrollOptions, NULL },
- /* 70 */ { SQL_API_SQLSETSTMTATTR, "SQLSetStmtAttr", SQLSetStmtAttr, NULL },
- /* 71 */ { SQL_API_SQLSETSTMTOPTION, "SQLSetStmtOption", SQLSetStmtOption, NULL },
- /* 72 */ { SQL_API_SQLSPECIALCOLUMNS, "SQLSpecialColumns", SQLSpecialColumns, NULL },
- /* 73 */ { SQL_API_SQLSTATISTICS, "SQLStatistics", SQLStatistics, NULL },
- /* 74 */ { SQL_API_SQLTABLEPRIVILEGES, "SQLTablePrivileges", SQLTablePrivileges, NULL },
- /* 75 */ { SQL_API_SQLTABLES, "SQLTables", SQLTables, NULL },
- /* 76 */ { SQL_API_SQLTRANSACT, "SQLTransact", SQLTransact, NULL },
- /* 77 */ { SQL_API_SQLGETDIAGREC, "SQLGetDiagRec", SQLGetDiagRec, NULL },
+ /* 00 */ { SQL_API_SQLALLOCCONNECT, "SQLAllocConnect", SQLAllocConnect, NULL, NULL },
+ /* 01 */ { SQL_API_SQLALLOCENV, "SQLAllocEnv", SQLAllocEnv, NULL, NULL },
+ /* 02 */ { SQL_API_SQLALLOCHANDLE, "SQLAllocHandle", SQLAllocHandle, NULL, NULL },
+ /* 03 */ { SQL_API_SQLALLOCSTMT, "SQLAllocStmt", SQLAllocStmt, NULL, NULL },
+ /* 04 */ { SQL_API_SQLALLOCHANDLESTD, "SQLAllocHandleStd", SQLAllocHandleStd, NULL, NULL },
+ /* 05 */ { SQL_API_SQLBINDCOL, "SQLBindCol", SQLBindCol, NULL, NULL },
+ /* 06 */ { SQL_API_SQLBINDPARAM, "SQLBindParam", SQLBindParam, NULL, NULL },
+ /* 07 */ { SQL_API_SQLBINDPARAMETER, "SQLBindParameter", SQLBindParameter, NULL, NULL },
+ /* 08 */ { SQL_API_SQLBROWSECONNECT, "SQLBrowseConnect", SQLBrowseConnect, NULL, NULL },
+ /* 09 */ { SQL_API_SQLBULKOPERATIONS, "SQLBulkOperations", SQLBulkOperations, NULL, NULL },
+ /* 10 */ { SQL_API_SQLCANCEL, "SQLCancel", SQLCancel, NULL, NULL },
+ /* 11 */ { SQL_API_SQLCLOSECURSOR, "SQLCloseCursor", SQLCloseCursor, NULL, NULL },
+ /* 12 */ { SQL_API_SQLCOLATTRIBUTE, "SQLColAttribute", SQLColAttribute, NULL, NULL },
+ /* 13 */ { SQL_API_SQLCOLATTRIBUTES, "SQLColAttributes", SQLColAttributes, NULL, NULL },
+ /* 14 */ { SQL_API_SQLCOLUMNPRIVILEGES, "SQLColumnPrivileges", SQLColumnPrivileges, NULL, NULL },
+ /* 15 */ { SQL_API_SQLCOLUMNS, "SQLColumns", SQLColumns, NULL, NULL },
+ /* 16 */ { SQL_API_SQLCONNECT, "SQLConnect", SQLConnect, NULL, NULL },
+ /* 17 */ { SQL_API_SQLCOPYDESC, "SQLCopyDesc", SQLCopyDesc, NULL, NULL },
+ /* 18 */ { SQL_API_SQLDATASOURCES, "SQLDataSources", SQLDataSources, NULL, NULL },
+ /* 19 */ { SQL_API_SQLDESCRIBECOL, "SQLDescribeCol", SQLDescribeCol, NULL, NULL },
+ /* 20 */ { SQL_API_SQLDESCRIBEPARAM, "SQLDescribeParam", SQLDescribeParam, NULL, NULL },
+ /* 21 */ { SQL_API_SQLDISCONNECT, "SQLDisconnect", SQLDisconnect, NULL, NULL },
+ /* 22 */ { SQL_API_SQLDRIVERCONNECT, "SQLDriverConnect", SQLDriverConnect, NULL, NULL },
+ /* 23 */ { SQL_API_SQLDRIVERS, "SQLDrivers", SQLDrivers, NULL, NULL },
+ /* 24 */ { SQL_API_SQLENDTRAN, "SQLEndTran", SQLEndTran, NULL, NULL },
+ /* 25 */ { SQL_API_SQLERROR, "SQLError", SQLError, NULL, NULL },
+ /* 26 */ { SQL_API_SQLEXECDIRECT, "SQLExecDirect", SQLExecDirect, NULL, NULL },
+ /* 27 */ { SQL_API_SQLEXECUTE, "SQLExecute", SQLExecute, NULL, NULL },
+ /* 28 */ { SQL_API_SQLEXTENDEDFETCH, "SQLExtendedFetch", SQLExtendedFetch, NULL, NULL },
+ /* 29 */ { SQL_API_SQLFETCH, "SQLFetch", SQLFetch, NULL, NULL },
+ /* 30 */ { SQL_API_SQLFETCHSCROLL, "SQLFetchScroll", SQLFetchScroll, NULL, NULL },
+ /* 31 */ { SQL_API_SQLFOREIGNKEYS, "SQLForeignKeys", SQLForeignKeys, NULL, NULL },
+ /* 32 */ { SQL_API_SQLFREEENV, "SQLFreeEnv", SQLFreeEnv, NULL, NULL },
+ /* 33 */ { SQL_API_SQLFREEHANDLE, "SQLFreeHandle", SQLFreeHandle, NULL, NULL },
+ /* 34 */ { SQL_API_SQLFREESTMT, "SQLFreeStmt", SQLFreeStmt, NULL, NULL },
+ /* 35 */ { SQL_API_SQLFREECONNECT, "SQLFreeConnect", SQLFreeConnect, NULL, NULL },
+ /* 36 */ { SQL_API_SQLGETCONNECTATTR, "SQLGetConnectAttr", SQLGetConnectAttr, NULL, NULL },
+ /* 37 */ { SQL_API_SQLGETCONNECTOPTION, "SQLGetConnectOption", SQLGetConnectOption, NULL, NULL },
+ /* 38 */ { SQL_API_SQLGETCURSORNAME, "SQLGetCursorName", SQLGetCursorName, NULL, NULL },
+ /* 39 */ { SQL_API_SQLGETDATA, "SQLGetData", SQLGetData, NULL, NULL },
+ /* 40 */ { SQL_API_SQLGETDESCFIELD, "SQLGetDescField", SQLGetDescField, NULL, NULL },
+ /* 41 */ { SQL_API_SQLGETDESCREC, "SQLGetDescRec", SQLGetDescRec, NULL, NULL },
+ /* 42 */ { SQL_API_SQLGETDIAGFIELD, "SQLGetDiagField", SQLGetDiagField, NULL, NULL },
+ /* 43 */ { SQL_API_SQLGETENVATTR, "SQLGetEnvAttr", SQLGetEnvAttr, NULL, NULL },
+ /* 44 */ { SQL_API_SQLGETFUNCTIONS, "SQLGetFunctions", SQLGetFunctions, NULL, NULL },
+ /* 45 */ { SQL_API_SQLGETINFO, "SQLGetInfo", SQLGetInfo, NULL, NULL },
+ /* 46 */ { SQL_API_SQLGETSTMTATTR, "SQLGetStmtAttr", SQLGetStmtAttr, NULL, NULL },
+ /* 47 */ { SQL_API_SQLGETSTMTOPTION, "SQLGetStmtOption", SQLGetStmtOption, NULL, NULL },
+ /* 48 */ { SQL_API_SQLGETTYPEINFO, "SQLGetTypeInfo", SQLGetTypeInfo, NULL, NULL },
+ /* 49 */ { SQL_API_SQLMORERESULTS, "SQLMoreResults", SQLMoreResults, NULL, NULL },
+ /* 50 */ { SQL_API_SQLNATIVESQL, "SQLNativeSql", SQLNativeSql, NULL, NULL },
+ /* 51 */ { SQL_API_SQLNUMPARAMS, "SQLNumParams", SQLNumParams, NULL, NULL },
+ /* 52 */ { SQL_API_SQLNUMRESULTCOLS, "SQLNumResultCols", SQLNumResultCols, NULL, NULL },
+ /* 53 */ { SQL_API_SQLPARAMDATA, "SQLParamData", SQLParamData, NULL, NULL },
+ /* 54 */ { SQL_API_SQLPARAMOPTIONS, "SQLParamOptions", SQLParamOptions, NULL, NULL },
+ /* 55 */ { SQL_API_SQLPREPARE, "SQLPrepare", SQLPrepare, NULL, NULL },
+ /* 56 */ { SQL_API_SQLPRIMARYKEYS, "SQLPrimaryKeys", SQLPrimaryKeys, NULL, NULL },
+ /* 57 */ { SQL_API_SQLPROCEDURECOLUMNS, "SQLProcedureColumns", SQLProcedureColumns, NULL, NULL },
+ /* 58 */ { SQL_API_SQLPROCEDURES, "SQLProcedures", SQLProcedures, NULL, NULL },
+ /* 59 */ { SQL_API_SQLPUTDATA, "SQLPutData", SQLPutData, NULL, NULL },
+ /* 60 */ { SQL_API_SQLROWCOUNT, "SQLRowCount", SQLRowCount, NULL, NULL },
+ /* 61 */ { SQL_API_SQLSETCONNECTATTR, "SQLSetConnectAttr", SQLSetConnectAttr, NULL, NULL },
+ /* 62 */ { SQL_API_SQLSETCONNECTOPTION, "SQLSetConnectOption", SQLSetConnectOption, NULL, NULL },
+ /* 63 */ { SQL_API_SQLSETCURSORNAME, "SQLSetCursorName", SQLSetCursorName, NULL, NULL },
+ /* 64 */ { SQL_API_SQLSETDESCFIELD, "SQLSetDescField", SQLSetDescField, NULL, NULL },
+ /* 65 */ { SQL_API_SQLSETDESCREC, "SQLSetDescRec", SQLSetDescRec, NULL, NULL },
+ /* 66 */ { SQL_API_SQLSETENVATTR, "SQLSetEnvAttr", SQLSetEnvAttr, NULL, NULL },
+ /* 67 */ { SQL_API_SQLSETPARAM, "SQLSetParam", SQLSetParam, NULL, NULL },
+ /* 68 */ { SQL_API_SQLSETPOS, "SQLSetPos", SQLSetPos, NULL, NULL },
+ /* 69 */ { SQL_API_SQLSETSCROLLOPTIONS, "SQLSetScrollOptions", SQLSetScrollOptions, NULL, NULL },
+ /* 70 */ { SQL_API_SQLSETSTMTATTR, "SQLSetStmtAttr", SQLSetStmtAttr, NULL, NULL },
+ /* 71 */ { SQL_API_SQLSETSTMTOPTION, "SQLSetStmtOption", SQLSetStmtOption, NULL, NULL },
+ /* 72 */ { SQL_API_SQLSPECIALCOLUMNS, "SQLSpecialColumns", SQLSpecialColumns, NULL, NULL },
+ /* 73 */ { SQL_API_SQLSTATISTICS, "SQLStatistics", SQLStatistics, NULL, NULL },
+ /* 74 */ { SQL_API_SQLTABLEPRIVILEGES, "SQLTablePrivileges", SQLTablePrivileges, NULL, NULL },
+ /* 75 */ { SQL_API_SQLTABLES, "SQLTables", SQLTables, NULL, NULL },
+ /* 76 */ { SQL_API_SQLTRANSACT, "SQLTransact", SQLTransact, NULL, NULL },
+ /* 77 */ { SQL_API_SQLGETDIAGREC, "SQLGetDiagRec", SQLGetDiagRec, NULL, NULL },
};
static PROXYHANDLE gProxyHandle;
@@ -156,12 +159,301 @@ static PROXYHANDLE gProxyHandle;
} \
}
-SQLRETURN SQLDummyFunc()
+static SQLRETURN SQLDummyFunc(void)
{
- TRACE("SQLDummyFunc: \n");
+ TRACE("SQLDummyFunc:\n");
return SQL_SUCCESS;
}
+/***********************************************************************
+ * ODBC_ReplicateODBCInstToRegistry
+ *
+ * PARAMS
+ *
+ * RETURNS
+ *
+ * Utility to ODBC_ReplicateToRegistry to replicate the drivers of the
+ * ODBCINST.INI settings
+ *
+ * The driver settings are not replicated to the registry. If we were to
+ * replicate them we would need to decide whether to replicate all settings
+ * or to do some translation; whether to remove any entries present only in
+ * the windows registry, etc.
+ */
+
+static void ODBC_ReplicateODBCInstToRegistry (SQLHENV hEnv)
+{
+ HKEY hODBCInst;
+ LONG reg_ret;
+ int success;
+
+ success = 0;
+ TRACE ("Driver settings are not currently replicated to the registry\n");
+ if ((reg_ret = RegCreateKeyExA (HKEY_LOCAL_MACHINE,
+ "Software\\ODBC\\ODBCINST.INI", 0, NULL,
+ REG_OPTION_NON_VOLATILE,
+ KEY_ALL_ACCESS /* a couple more than we need */, NULL,
+ &hODBCInst, NULL)) == ERROR_SUCCESS)
+ {
+ HKEY hDrivers;
+ if ((reg_ret = RegCreateKeyExA (hODBCInst, "ODBC Drivers", 0,
+ NULL, REG_OPTION_NON_VOLATILE,
+ KEY_ALL_ACCESS /* overkill */, NULL, &hDrivers, NULL))
+ == ERROR_SUCCESS)
+ {
+ SQLRETURN sql_ret;
+ SQLUSMALLINT dirn;
+ CHAR desc [256];
+ SQLSMALLINT sizedesc;
+
+ success = 1;
+ dirn = SQL_FETCH_FIRST;
+ while ((sql_ret = SQLDrivers (hEnv, dirn, (SQLCHAR*)desc, sizeof(desc),
+ &sizedesc, NULL, 0, NULL)) == SQL_SUCCESS ||
+ sql_ret == SQL_SUCCESS_WITH_INFO)
+ {
+ /* FIXME Do some proper handling of the SUCCESS_WITH_INFO */
+ dirn = SQL_FETCH_NEXT;
+ if (sizedesc == lstrlenA(desc))
+ {
+ HKEY hThis;
+ if ((reg_ret = RegQueryValueExA (hDrivers, desc, NULL,
+ NULL, NULL, NULL)) == ERROR_FILE_NOT_FOUND)
+ {
+ if ((reg_ret = RegSetValueExA (hDrivers, desc, 0,
+ REG_SZ, (const BYTE *)"Installed", 10)) != ERROR_SUCCESS)
+ {
+ TRACE ("Error %d replicating driver %s\n",
+ reg_ret, desc);
+ success = 0;
+ }
+ }
+ else if (reg_ret != ERROR_SUCCESS)
+ {
+ TRACE ("Error %d checking for %s in drivers\n",
+ reg_ret, desc);
+ success = 0;
+ }
+ if ((reg_ret = RegCreateKeyExA (hODBCInst, desc, 0,
+ NULL, REG_OPTION_NON_VOLATILE,
+ KEY_ALL_ACCESS, NULL, &hThis, NULL))
+ == ERROR_SUCCESS)
+ {
+ /* FIXME This is where the settings go.
+ * I suggest that if the disposition says it
+ * exists then we leave it alone. Alternatively
+ * include an extra value to flag that it is
+ * a replication of the unixODBC/iODBC/...
+ */
+ if ((reg_ret = RegCloseKey (hThis)) !=
+ ERROR_SUCCESS)
+ TRACE ("Error %d closing %s key\n", reg_ret,
+ desc);
+ }
+ else
+ {
+ TRACE ("Error %d ensuring driver key %s\n",
+ reg_ret, desc);
+ success = 0;
+ }
+ }
+ else
+ {
+ WARN ("Unusually long driver name %s not replicated\n",
+ desc);
+ success = 0;
+ }
+ }
+ if (sql_ret != SQL_NO_DATA)
+ {
+ TRACE ("Error %d enumerating drivers\n", (int)sql_ret);
+ success = 0;
+ }
+ if ((reg_ret = RegCloseKey (hDrivers)) != ERROR_SUCCESS)
+ {
+ TRACE ("Error %d closing hDrivers\n", reg_ret);
+ }
+ }
+ else
+ {
+ TRACE ("Error %d opening HKLM\\S\\O\\OI\\Drivers\n", reg_ret);
+ }
+ if ((reg_ret = RegCloseKey (hODBCInst)) != ERROR_SUCCESS)
+ {
+ TRACE ("Error %d closing HKLM\\S\\O\\ODBCINST.INI\n", reg_ret);
+ }
+ }
+ else
+ {
+ TRACE ("Error %d opening HKLM\\S\\O\\ODBCINST.INI\n", reg_ret);
+ }
+ if (!success)
+ {
+ WARN ("May not have replicated all ODBC drivers to the registry\n");
+ }
+}
+
+/***********************************************************************
+ * ODBC_ReplicateODBCToRegistry
+ *
+ * PARAMS
+ *
+ * RETURNS
+ *
+ * Utility to ODBC_ReplicateToRegistry to replicate either the USER or
+ * SYSTEM dsns
+ *
+ * For now simply place the "Driver description" (as returned by SQLDataSources)
+ * into the registry as the driver. This is enough to satisfy Crystal's
+ * requirement that there be a driver entry. (It doesn't seem to care what
+ * the setting is).
+ * A slightly more accurate setting would be to access the registry to find
+ * the actual driver library for the given description (which appears to map
+ * to one of the HKLM/Software/ODBC/ODBCINST.INI keys). (If you do this note
+ * that this will add a requirement that this function be called after
+ * ODBC_ReplicateODBCInstToRegistry)
+ */
+static void ODBC_ReplicateODBCToRegistry (int is_user, SQLHENV hEnv)
+{
+ HKEY hODBC;
+ LONG reg_ret;
+ SQLRETURN sql_ret;
+ SQLUSMALLINT dirn;
+ CHAR dsn [SQL_MAX_DSN_LENGTH + 1];
+ SQLSMALLINT sizedsn;
+ CHAR desc [256];
+ SQLSMALLINT sizedesc;
+ int success;
+ const char *which = is_user ? "user" : "system";
+
+ success = 0;
+ if ((reg_ret = RegCreateKeyExA (
+ is_user ? HKEY_CURRENT_USER : HKEY_LOCAL_MACHINE,
+ "Software\\ODBC\\ODBC.INI", 0, NULL, REG_OPTION_NON_VOLATILE,
+ KEY_ALL_ACCESS /* a couple more than we need */, NULL, &hODBC,
+ NULL)) == ERROR_SUCCESS)
+ {
+ success = 1;
+ dirn = is_user ? SQL_FETCH_FIRST_USER : SQL_FETCH_FIRST_SYSTEM;
+ while ((sql_ret = SQLDataSources (hEnv, dirn,
+ (SQLCHAR*)dsn, sizeof(dsn), &sizedsn,
+ (SQLCHAR*)desc, sizeof(desc), &sizedesc)) == SQL_SUCCESS
+ || sql_ret == SQL_SUCCESS_WITH_INFO)
+ {
+ /* FIXME Do some proper handling of the SUCCESS_WITH_INFO */
+ dirn = SQL_FETCH_NEXT;
+ if (sizedsn == lstrlenA(dsn) && sizedesc == lstrlenA(desc))
+ {
+ HKEY hDSN;
+ if ((reg_ret = RegCreateKeyExA (hODBC, dsn, 0,
+ NULL, REG_OPTION_NON_VOLATILE,
+ KEY_ALL_ACCESS, NULL, &hDSN, NULL))
+ == ERROR_SUCCESS)
+ {
+ static const char DRIVERKEY[] = "Driver";
+ if ((reg_ret = RegQueryValueExA (hDSN, DRIVERKEY,
+ NULL, NULL, NULL, NULL))
+ == ERROR_FILE_NOT_FOUND)
+ {
+ if ((reg_ret = RegSetValueExA (hDSN, DRIVERKEY, 0,
+ REG_SZ, (LPBYTE)desc, sizedesc)) != ERROR_SUCCESS)
+ {
+ TRACE ("Error %d replicating description of "
+ "%s(%s)\n", reg_ret, dsn, desc);
+ success = 0;
+ }
+ }
+ else if (reg_ret != ERROR_SUCCESS)
+ {
+ TRACE ("Error %d checking for description of %s\n",
+ reg_ret, dsn);
+ success = 0;
+ }
+ if ((reg_ret = RegCloseKey (hDSN)) != ERROR_SUCCESS)
+ {
+ TRACE ("Error %d closing %s DSN key %s\n",
+ reg_ret, which, dsn);
+ }
+ }
+ else
+ {
+ TRACE ("Error %d opening %s DSN key %s\n",
+ reg_ret, which, dsn);
+ success = 0;
+ }
+ }
+ else
+ {
+ WARN ("Unusually long %s data source name %s (%s) not "
+ "replicated\n", which, dsn, desc);
+ success = 0;
+ }
+ }
+ if (sql_ret != SQL_NO_DATA)
+ {
+ TRACE ("Error %d enumerating %s datasources\n",
+ (int)sql_ret, which);
+ success = 0;
+ }
+ if ((reg_ret = RegCloseKey (hODBC)) != ERROR_SUCCESS)
+ {
+ TRACE ("Error %d closing %s ODBC.INI registry key\n", reg_ret,
+ which);
+ }
+ }
+ else
+ {
+ TRACE ("Error %d creating/opening %s ODBC.INI registry key\n",
+ reg_ret, which);
+ }
+ if (!success)
+ {
+ WARN ("May not have replicated all %s ODBC DSNs to the registry\n",
+ which);
+ }
+}
+
+/***********************************************************************
+ * ODBC_ReplicateToRegistry
+ *
+ * PARAMS
+ *
+ * RETURNS
+ *
+ * Unfortunately some of the functions that Windows documents as being part
+ * of the ODBC API it implements directly during compilation or something
+ * in terms of registry access functions.
+ * e.g. SQLGetInstalledDrivers queries the list at
+ * HKEY_LOCAL_MACHINE\Software\ODBC\ODBCINST.INI\ODBC Drivers
+ *
+ * This function is called when the driver manager is loaded and is used
+ * to replicate the appropriate details into the Wine registry
+ */
+
+static void ODBC_ReplicateToRegistry (void)
+{
+ SQLRETURN sql_ret;
+ SQLHENV hEnv;
+
+ if ((sql_ret = SQLAllocEnv (&hEnv)) == SQL_SUCCESS)
+ {
+ ODBC_ReplicateODBCInstToRegistry (hEnv);
+ ODBC_ReplicateODBCToRegistry (0 /* system dsns */, hEnv);
+ ODBC_ReplicateODBCToRegistry (1 /* user dsns */, hEnv);
+
+ if ((sql_ret = SQLFreeEnv (hEnv)) != SQL_SUCCESS)
+ {
+ TRACE ("Error %d freeing the SQL environment.\n", (int)sql_ret);
+ }
+ }
+ else
+ {
+ TRACE ("Error %d opening an SQL environment.\n", (int)sql_ret);
+ WARN ("The external ODBC settings have not been replicated to the"
+ " Wine registry\n");
+ }
+}
+
/***********************************************************************
* DllMain [Internal] Initializes the internal 'ODBC32.DLL'.
*
@@ -178,14 +470,17 @@ SQLRETURN SQLDummyFunc()
BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved)
{
int i;
- TRACE("Initializing or Finalizing proxy ODBC: %p,%lx,%p\n", hinstDLL, fdwReason, lpvReserved);
+ TRACE("Initializing or Finalizing proxy ODBC: %p,%x,%p\n", hinstDLL, fdwReason, lpvReserved);
if (fdwReason == DLL_PROCESS_ATTACH)
{
TRACE("Loading ODBC...\n");
DisableThreadLibraryCalls(hinstDLL);
if (ODBC_LoadDriverManager())
+ {
ODBC_LoadDMFunctions();
+ ODBC_ReplicateToRegistry();
+ }
}
else if (fdwReason == DLL_PROCESS_DETACH)
{
@@ -197,19 +492,17 @@ BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved)
gProxyHandle.functions[i].func = SQLDummyFunc;
}
}
-#ifndef __REACTOS__
+
if (gProxyHandle.dmHandle)
{
wine_dlclose(gProxyHandle.dmHandle,NULL,0);
gProxyHandle.dmHandle = NULL;
}
-#endif
}
return TRUE;
}
-
/***********************************************************************
* ODBC_LoadDriverManager [Internal] Load ODBC library.
*
@@ -223,41 +516,28 @@ BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved)
static BOOL ODBC_LoadDriverManager(void)
{
const char *s = getenv("LIB_ODBC_DRIVER_MANAGER");
-#ifndef __REACTOS__
char error[256];
-#endif
TRACE("\n");
gProxyHandle.bFunctionReady = FALSE;
- gProxyHandle.nErrorType = ERROR_LIBRARY_NOT_FOUND;
- if (s!= NULL && strlen (s) >= sizeof(gProxyHandle.dmLibName))
- {
- ERR("Driver name too long (%s)\n",s);
- return FALSE;
- }
- if (s == NULL || strlen(s) == 0)
- s = "libodbc.so";
- strcpy(gProxyHandle.dmLibName, s);
-#ifndef __REACTOS__
- gProxyHandle.dmHandle = wine_dlopen(gProxyHandle.dmLibName, RTLD_LAZY, error, sizeof(error));
+#ifdef SONAME_LIBODBC
+ if (!s || !s[0]) s = SONAME_LIBODBC;
+#endif
+ if (!s || !s[0]) goto failed;
- if (gProxyHandle.dmHandle == NULL) /* fail to load unixODBC driver manager */
- {
- WARN("failed to open library %s: %s\n", gProxyHandle.dmLibName, error);
- gProxyHandle.dmLibName[0] = '\0';
- gProxyHandle.nErrorType = ERROR_LIBRARY_NOT_FOUND;
- return FALSE;
- }
- else
+ gProxyHandle.dmHandle = wine_dlopen(s, RTLD_LAZY | RTLD_GLOBAL, error, sizeof(error));
+
+ if (gProxyHandle.dmHandle != NULL)
{
gProxyHandle.nErrorType = ERROR_FREE;
return TRUE;
}
-#else
+failed:
+ WARN("failed to open library %s: %s\n", debugstr_a(s), error);
+ gProxyHandle.nErrorType = ERROR_LIBRARY_NOT_FOUND;
return FALSE;
-#endif
}
@@ -273,16 +553,16 @@ static BOOL ODBC_LoadDriverManager(void)
static BOOL ODBC_LoadDMFunctions(void)
{
-#ifndef __REACTOS__
int i;
char error[256];
-#endif
if (gProxyHandle.dmHandle == NULL)
return FALSE;
-#ifndef __REACTOS__
+
for ( i = 0; i < NUM_SQLFUNC; i ++ )
{
+ char * pFuncNameW;
+
gProxyHandle.functions[i] = template_func[i];
gProxyHandle.functions[i].func = wine_dlsym(gProxyHandle.dmHandle,
gProxyHandle.functions[i].name, error, sizeof(error));
@@ -292,10 +572,27 @@ static BOOL ODBC_LoadDMFunctions(void)
ERR("Failed to load function %s\n",gProxyHandle.functions[i].name);
gProxyHandle.functions[i].func = SQLDummyFunc;
}
+ else
+ {
+ /* Build Unicode function name for this function */
+ pFuncNameW = HeapAlloc(GetProcessHeap(), 0, strlen(gProxyHandle.functions[i].name) + 2);
+ strcpy(pFuncNameW, gProxyHandle.functions[i].name);
+ pFuncNameW[strlen(gProxyHandle.functions[i].name) + 1] = '\0';
+ pFuncNameW[strlen(gProxyHandle.functions[i].name)] = 'W';
+
+ gProxyHandle.functions[i].funcW = wine_dlsym(gProxyHandle.dmHandle,
+ pFuncNameW, error, sizeof(error));
+ if (error[0])
+ {
+/* TRACE("Failed to load function %s, possibly no Unicode version is required\n", pFuncNameW); */
+ gProxyHandle.functions[i].funcW = NULL;
+ }
+ HeapFree(GetProcessHeap(), 0, pFuncNameW);
+ }
}
gProxyHandle.bFunctionReady = TRUE;
-#endif
+
return TRUE;
}
@@ -356,7 +653,7 @@ SQLRETURN WINAPI SQLAllocHandle(SQLSMALLINT HandleType, SQLHANDLE InputHandle, S
if (!gProxyHandle.bFunctionReady || gProxyHandle.dmHandle == NULL)
{
if (gProxyHandle.nErrorType == ERROR_LIBRARY_NOT_FOUND)
- WARN("ProxyODBC: Can not load ODBC driver manager library.\n");
+ WARN("ProxyODBC: Cannot load ODBC driver manager library.\n");
if (HandleType == SQL_HANDLE_ENV)
*OutputHandle = SQL_NULL_HENV;
@@ -409,12 +706,12 @@ SQLRETURN WINAPI SQLAllocStmt(SQLHDBC ConnectionHandle, SQLHSTMT *StatementHandl
SQLRETURN WINAPI SQLAllocHandleStd( SQLSMALLINT HandleType,
SQLHANDLE InputHandle, SQLHANDLE *OutputHandle)
{
- TRACE("ProxyODBC: SQLAllocHandelStd.\n");
+ TRACE("ProxyODBC: SQLAllocHandleStd.\n");
if (!gProxyHandle.bFunctionReady || gProxyHandle.dmHandle == NULL)
{
if (gProxyHandle.nErrorType == ERROR_LIBRARY_NOT_FOUND)
- WARN("ProxyODBC: Can not load ODBC driver manager library.\n");
+ WARN("ProxyODBC: Cannot load ODBC driver manager library.\n");
if (HandleType == SQL_HANDLE_ENV)
*OutputHandle = SQL_NULL_HENV;
@@ -439,8 +736,8 @@ SQLRETURN WINAPI SQLAllocHandleStd( SQLSMALLINT HandleType,
*/
SQLRETURN WINAPI SQLBindCol(SQLHSTMT StatementHandle,
SQLUSMALLINT ColumnNumber, SQLSMALLINT TargetType,
- SQLPOINTER TargetValue, SQLINTEGER BufferLength,
- SQLINTEGER *StrLen_or_Ind)
+ SQLPOINTER TargetValue, SQLLEN BufferLength,
+ SQLLEN *StrLen_or_Ind)
{
TRACE("\n");
@@ -462,9 +759,9 @@ SQLRETURN WINAPI SQLBindCol(SQLHSTMT StatementHandle,
*/
SQLRETURN WINAPI SQLBindParam(SQLHSTMT StatementHandle,
SQLUSMALLINT ParameterNumber, SQLSMALLINT ValueType,
- SQLSMALLINT ParameterType, SQLUINTEGER LengthPrecision,
+ SQLSMALLINT ParameterType, SQLULEN LengthPrecision,
SQLSMALLINT ParameterScale, SQLPOINTER ParameterValue,
- SQLINTEGER *StrLen_or_Ind)
+ SQLLEN *StrLen_or_Ind)
{
TRACE("\n");
@@ -560,8 +857,8 @@ SQLRETURN WINAPI SQLConnect(SQLHDBC ConnectionHandle,
CHECK_READY_AND_dmHandle();
- strcpy(gProxyHandle.ServerName, (const char*)ServerName);
- strcpy(gProxyHandle.UserName, (const char*)UserName);
+ strcpy( (LPSTR)gProxyHandle.ServerName, (LPSTR)ServerName );
+ strcpy( (LPSTR)gProxyHandle.UserName, (LPSTR)UserName );
assert(gProxyHandle.functions[SQLAPI_INDEX_SQLCONNECT].func);
ret=(gProxyHandle.functions[SQLAPI_INDEX_SQLCONNECT].func)
@@ -612,7 +909,7 @@ SQLRETURN WINAPI SQLDataSources(SQLHENV EnvironmentHandle,
(EnvironmentHandle, Direction, ServerName,
BufferLength1, NameLength1, Description, BufferLength2, NameLength2);
- if (WINE_TRACE_ON(odbc))
+ if (TRACE_ON(odbc))
{
TRACE("returns: %d \t", ret);
if (*NameLength1 > 0)
@@ -632,7 +929,7 @@ SQLRETURN WINAPI SQLDataSources(SQLHENV EnvironmentHandle,
SQLRETURN WINAPI SQLDescribeCol(SQLHSTMT StatementHandle,
SQLUSMALLINT ColumnNumber, SQLCHAR *ColumnName,
SQLSMALLINT BufferLength, SQLSMALLINT *NameLength,
- SQLSMALLINT *DataType, SQLUINTEGER *ColumnSize,
+ SQLSMALLINT *DataType, SQLULEN *ColumnSize,
SQLSMALLINT *DecimalDigits, SQLSMALLINT *Nullable)
{
TRACE("\n");
@@ -746,7 +1043,7 @@ SQLRETURN WINAPI SQLFetch(SQLHSTMT StatementHandle)
/*************************************************************************
* SQLFetchScroll [ODBC32.030]
*/
-SQLRETURN WINAPI SQLFetchScroll(SQLHSTMT StatementHandle, SQLSMALLINT FetchOrientation, SQLINTEGER FetchOffset)
+SQLRETURN WINAPI SQLFetchScroll(SQLHSTMT StatementHandle, SQLSMALLINT FetchOrientation, SQLLEN FetchOffset)
{
TRACE("\n");
@@ -883,8 +1180,8 @@ SQLRETURN WINAPI SQLGetCursorName(SQLHSTMT StatementHandle,
*/
SQLRETURN WINAPI SQLGetData(SQLHSTMT StatementHandle,
SQLUSMALLINT ColumnNumber, SQLSMALLINT TargetType,
- SQLPOINTER TargetValue, SQLINTEGER BufferLength,
- SQLINTEGER *StrLen_or_Ind)
+ SQLPOINTER TargetValue, SQLLEN BufferLength,
+ SQLLEN *StrLen_or_Ind)
{
TRACE("\n");
@@ -923,7 +1220,7 @@ SQLRETURN WINAPI SQLGetDescRec(SQLHDESC DescriptorHandle,
SQLSMALLINT RecNumber, SQLCHAR *Name,
SQLSMALLINT BufferLength, SQLSMALLINT *StringLength,
SQLSMALLINT *Type, SQLSMALLINT *SubType,
- SQLINTEGER *Length, SQLSMALLINT *Precision,
+ SQLLEN *Length, SQLSMALLINT *Precision,
SQLSMALLINT *Scale, SQLSMALLINT *Nullable)
{
TRACE("\n");
@@ -1119,7 +1416,7 @@ SQLRETURN WINAPI SQLPrepare(SQLHSTMT StatementHandle, SQLCHAR *StatementText, SQ
/*************************************************************************
* SQLPutData [ODBC32.049]
*/
-SQLRETURN WINAPI SQLPutData(SQLHSTMT StatementHandle, SQLPOINTER Data, SQLINTEGER StrLen_or_Ind)
+SQLRETURN WINAPI SQLPutData(SQLHSTMT StatementHandle, SQLPOINTER Data, SQLLEN StrLen_or_Ind)
{
TRACE("\n");
@@ -1134,7 +1431,7 @@ SQLRETURN WINAPI SQLPutData(SQLHSTMT StatementHandle, SQLPOINTER Data, SQLINTEGE
/*************************************************************************
* SQLRowCount [ODBC32.020]
*/
-SQLRETURN WINAPI SQLRowCount(SQLHSTMT StatementHandle, SQLINTEGER *RowCount)
+SQLRETURN WINAPI SQLRowCount(SQLHSTMT StatementHandle, SQLLEN *RowCount)
{
TRACE("\n");
@@ -1165,7 +1462,7 @@ SQLRETURN WINAPI SQLSetConnectAttr(SQLHDBC ConnectionHandle, SQLINTEGER Attribut
/*************************************************************************
* SQLSetConnectOption [ODBC32.050]
*/
-SQLRETURN WINAPI SQLSetConnectOption(SQLHDBC ConnectionHandle, SQLUSMALLINT Option, SQLUINTEGER Value)
+SQLRETURN WINAPI SQLSetConnectOption(SQLHDBC ConnectionHandle, SQLUSMALLINT Option, SQLULEN Value)
{
TRACE("\n");
@@ -1214,10 +1511,10 @@ SQLRETURN WINAPI SQLSetDescField(SQLHDESC DescriptorHandle,
*/
SQLRETURN WINAPI SQLSetDescRec(SQLHDESC DescriptorHandle,
SQLSMALLINT RecNumber, SQLSMALLINT Type,
- SQLSMALLINT SubType, SQLINTEGER Length,
+ SQLSMALLINT SubType, SQLLEN Length,
SQLSMALLINT Precision, SQLSMALLINT Scale,
- SQLPOINTER Data, SQLINTEGER *StringLength,
- SQLINTEGER *Indicator)
+ SQLPOINTER Data, SQLLEN *StringLength,
+ SQLLEN *Indicator)
{
TRACE("\n");
@@ -1252,9 +1549,9 @@ SQLRETURN WINAPI SQLSetEnvAttr(SQLHENV EnvironmentHandle,
*/
SQLRETURN WINAPI SQLSetParam(SQLHSTMT StatementHandle,
SQLUSMALLINT ParameterNumber, SQLSMALLINT ValueType,
- SQLSMALLINT ParameterType, SQLUINTEGER LengthPrecision,
+ SQLSMALLINT ParameterType, SQLULEN LengthPrecision,
SQLSMALLINT ParameterScale, SQLPOINTER ParameterValue,
- SQLINTEGER *StrLen_or_Ind)
+ SQLLEN *StrLen_or_Ind)
{
TRACE("\n");
@@ -1287,7 +1584,7 @@ SQLRETURN WINAPI SQLSetStmtAttr(SQLHSTMT StatementHandle,
/*************************************************************************
* SQLSetStmtOption [ODBC32.051]
*/
-SQLRETURN WINAPI SQLSetStmtOption(SQLHSTMT StatementHandle, SQLUSMALLINT Option, SQLUINTEGER Value)
+SQLRETURN WINAPI SQLSetStmtOption(SQLHSTMT StatementHandle, SQLUSMALLINT Option, SQLULEN Value)
{
TRACE("\n");
@@ -1423,7 +1720,7 @@ SQLRETURN WINAPI SQLColAttributes(
SQLPOINTER rgbDesc,
SQLSMALLINT cbDescMax,
SQLSMALLINT *pcbDesc,
- SQLINTEGER *pfDesc)
+ SQLLEN *pfDesc)
{
TRACE("\n");
@@ -1467,7 +1764,7 @@ SQLRETURN WINAPI SQLDescribeParam(
SQLHSTMT hstmt,
SQLUSMALLINT ipar,
SQLSMALLINT *pfSqlType,
- SQLUINTEGER *pcbParamDef,
+ SQLULEN *pcbParamDef,
SQLSMALLINT *pibScale,
SQLSMALLINT *pfNullable)
{
@@ -1745,11 +2042,11 @@ SQLRETURN WINAPI SQLBindParameter(
SQLSMALLINT fParamType,
SQLSMALLINT fCType,
SQLSMALLINT fSqlType,
- SQLUINTEGER cbColDef,
+ SQLULEN cbColDef,
SQLSMALLINT ibScale,
SQLPOINTER rgbValue,
- SQLINTEGER cbValueMax,
- SQLINTEGER *pcbValue)
+ SQLLEN cbValueMax,
+ SQLLEN *pcbValue)
{
TRACE("\n");
@@ -1792,7 +2089,7 @@ SQLRETURN WINAPI SQLDriverConnect(
SQLRETURN WINAPI SQLSetScrollOptions(
SQLHSTMT statement_handle,
SQLUSMALLINT f_concurrency,
- SQLINTEGER crow_keyset,
+ SQLLEN crow_keyset,
SQLUSMALLINT crow_rowset )
{
TRACE("\n");
@@ -1804,4 +2101,832 @@ SQLRETURN WINAPI SQLSetScrollOptions(
(statement_handle, f_concurrency, crow_keyset, crow_rowset);
}
+static int SQLColAttributes_KnownStringAttribute(SQLUSMALLINT fDescType)
+{
+ static const SQLUSMALLINT attrList[] =
+ {
+ SQL_COLUMN_OWNER_NAME,
+ SQL_COLUMN_QUALIFIER_NAME,
+ SQL_COLUMN_LABEL,
+ SQL_COLUMN_NAME,
+ SQL_COLUMN_TABLE_NAME,
+ SQL_COLUMN_TYPE_NAME,
+ SQL_DESC_BASE_COLUMN_NAME,
+ SQL_DESC_BASE_TABLE_NAME,
+ SQL_DESC_CATALOG_NAME,
+ SQL_DESC_LABEL,
+ SQL_DESC_LITERAL_PREFIX,
+ SQL_DESC_LITERAL_SUFFIX,
+ SQL_DESC_LOCAL_TYPE_NAME,
+ SQL_DESC_NAME,
+ SQL_DESC_SCHEMA_NAME,
+ SQL_DESC_TABLE_NAME,
+ SQL_DESC_TYPE_NAME,
+ };
+ unsigned int i;
+
+ for (i = 0; i < sizeof(attrList) / sizeof(SQLUSMALLINT); i++) {
+ if (attrList[i] == fDescType) return 1;
+ }
+ return 0;
+}
+
+/*************************************************************************
+ * SQLColAttributesW [ODBC32.106]
+ */
+SQLRETURN WINAPI SQLColAttributesW(
+ SQLHSTMT hstmt,
+ SQLUSMALLINT icol,
+ SQLUSMALLINT fDescType,
+ SQLPOINTER rgbDesc,
+ SQLSMALLINT cbDescMax,
+ SQLSMALLINT *pcbDesc,
+ SQLLEN *pfDesc)
+{
+ SQLRETURN iResult;
+
+ TRACE("hstmt=0x%08lx icol=%d fDescType=%d rgbDesc=%p cbDescMax=%d pcbDesc=%p pfDesc=%p\n",
+ hstmt, icol, fDescType, rgbDesc, cbDescMax, pcbDesc, pfDesc);
+
+ CHECK_dmHandle();
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLCOLATTRIBUTES].funcW);
+ iResult = (gProxyHandle.functions[SQLAPI_INDEX_SQLCOLATTRIBUTES].funcW)
+ (hstmt, icol, fDescType, rgbDesc, cbDescMax, pcbDesc, pfDesc);
+ if (iResult == SQL_SUCCESS && rgbDesc != NULL && SQLColAttributes_KnownStringAttribute(fDescType)) {
+ /*
+ TRACE("Dumping values fetched via SQLColAttributesW:\n");
+ TRACE(" Attribute name : %s\n", debugstr_w(rgbDesc));
+ TRACE(" Declared length: %d\n", *pcbDesc);
+ */
+ if (*pcbDesc != lstrlenW(rgbDesc) * 2) {
+ TRACE("CHEAT: resetting name length for ADO\n");
+ *pcbDesc = lstrlenW(rgbDesc) * 2;
+ }
+ }
+ return iResult;
+}
+
+/*************************************************************************
+ * SQLConnectW [ODBC32.107]
+ */
+SQLRETURN WINAPI SQLConnectW(SQLHDBC ConnectionHandle,
+ WCHAR *ServerName, SQLSMALLINT NameLength1,
+ WCHAR *UserName, SQLSMALLINT NameLength2,
+ WCHAR *Authentication, SQLSMALLINT NameLength3)
+{
+ SQLRETURN ret;
+ TRACE("(Server=%.*s)\n",NameLength1+3, debugstr_w(ServerName));
+
+ CHECK_READY_AND_dmHandle();
+
+ WideCharToMultiByte(
+ CP_UTF8, 0,
+ ServerName, NameLength1,
+ gProxyHandle.ServerName, sizeof(gProxyHandle.ServerName),
+ NULL, NULL);
+ WideCharToMultiByte(
+ CP_UTF8, 0,
+ UserName, NameLength2,
+ gProxyHandle.UserName, sizeof(gProxyHandle.UserName),
+ NULL, NULL);
+
+ assert(gProxyHandle.functions[SQLAPI_INDEX_SQLCONNECT].funcW);
+ ret=(gProxyHandle.functions[SQLAPI_INDEX_SQLCONNECT].funcW)
+ (ConnectionHandle, ServerName, NameLength1,
+ UserName, NameLength2, Authentication, NameLength3);
+
+ TRACE("returns %d\n",ret);
+ return ret;
+}
+
+/*************************************************************************
+ * SQLDescribeColW [ODBC32.108]
+ */
+SQLRETURN WINAPI SQLDescribeColW(SQLHSTMT StatementHandle,
+ SQLUSMALLINT ColumnNumber, SQLWCHAR *ColumnName,
+ SQLSMALLINT BufferLength, SQLSMALLINT *NameLength,
+ SQLSMALLINT *DataType, SQLULEN *ColumnSize,
+ SQLSMALLINT *DecimalDigits, SQLSMALLINT *Nullable)
+{
+ SQLRETURN iResult;
+ TRACE("\n");
+
+ CHECK_READY_AND_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLDESCRIBECOL].funcW);
+ iResult = (gProxyHandle.functions[SQLAPI_INDEX_SQLDESCRIBECOL].funcW)
+ (StatementHandle, ColumnNumber, ColumnName,
+ BufferLength, NameLength, DataType, ColumnSize, DecimalDigits, Nullable);
+ if (iResult >= 0) {
+ TRACE("Successfully recovered the following column information:\n");
+ TRACE("\tRequested column index: %d\n", ColumnNumber);
+ TRACE("\tAvailable length for column name: %d\n", BufferLength);
+ if (NameLength != NULL)
+ TRACE("\tActual length for column name: %d\n", *NameLength);
+ else TRACE("\tActual length for column name: (null)\n");
+ TRACE("\tReturned column name: %s\n", debugstr_w(ColumnName));
+ }
+ return iResult;
+}
+
+/*************************************************************************
+ * SQLErrorW [ODBC32.110]
+ */
+SQLRETURN WINAPI SQLErrorW(SQLHENV EnvironmentHandle,
+ SQLHDBC ConnectionHandle, SQLHSTMT StatementHandle,
+ WCHAR *Sqlstate, SQLINTEGER *NativeError,
+ WCHAR *MessageText, SQLSMALLINT BufferLength,
+ SQLSMALLINT *TextLength)
+{
+ TRACE("\n");
+
+ CHECK_READY_AND_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLERROR].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLERROR].funcW)
+ (EnvironmentHandle, ConnectionHandle, StatementHandle,
+ Sqlstate, NativeError, MessageText, BufferLength, TextLength);
+}
+
+/*************************************************************************
+ * SQLExecDirectW [ODBC32.111]
+ */
+SQLRETURN WINAPI SQLExecDirectW(SQLHSTMT StatementHandle,
+ WCHAR *StatementText, SQLINTEGER TextLength)
+{
+ TRACE("\n");
+
+ CHECK_READY_AND_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLEXECDIRECT].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLEXECDIRECT].funcW)
+ (StatementHandle, StatementText, TextLength);
+}
+
+/*************************************************************************
+ * SQLGetCursorNameW [ODBC32.117]
+ */
+SQLRETURN WINAPI SQLGetCursorNameW(SQLHSTMT StatementHandle,
+ WCHAR *CursorName, SQLSMALLINT BufferLength,
+ SQLSMALLINT *NameLength)
+{
+ TRACE("\n");
+
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLGETCURSORNAME].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLGETCURSORNAME].funcW)
+ (StatementHandle, CursorName, BufferLength, NameLength);
+}
+
+/*************************************************************************
+ * SQLPrepareW [ODBC32.119]
+ */
+SQLRETURN WINAPI SQLPrepareW(SQLHSTMT StatementHandle,
+ WCHAR *StatementText, SQLINTEGER TextLength)
+{
+ TRACE("\n");
+
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLPREPARE].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLPREPARE].funcW)
+ (StatementHandle, StatementText, TextLength);
+}
+
+/*************************************************************************
+ * SQLSetCursorNameW [ODBC32.121]
+ */
+SQLRETURN WINAPI SQLSetCursorNameW(SQLHSTMT StatementHandle, WCHAR *CursorName, SQLSMALLINT NameLength)
+{
+ TRACE("\n");
+
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLSETCURSORNAME].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLSETCURSORNAME].funcW)
+ (StatementHandle, CursorName, NameLength);
+}
+
+/*************************************************************************
+ * SQLColAttributeW [ODBC32.127]
+ */
+SQLRETURN WINAPI SQLColAttributeW (SQLHSTMT StatementHandle,
+ SQLUSMALLINT ColumnNumber, SQLUSMALLINT FieldIdentifier,
+ SQLPOINTER CharacterAttribute, SQLSMALLINT BufferLength,
+ SQLSMALLINT *StringLength, SQLPOINTER NumericAttribute)
+{
+ SQLRETURN iResult;
+
+ TRACE("StatementHandle=0x%08lx ColumnNumber=%d FieldIdentifier=%d CharacterAttribute=%p BufferLength=%d StringLength=%p NumericAttribute=%p\n",
+ StatementHandle, ColumnNumber, FieldIdentifier,
+ CharacterAttribute, BufferLength, StringLength, NumericAttribute);
+
+ CHECK_READY_AND_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLCOLATTRIBUTE].funcW);
+ iResult = (gProxyHandle.functions[SQLAPI_INDEX_SQLCOLATTRIBUTE].funcW)
+ (StatementHandle, ColumnNumber, FieldIdentifier,
+ CharacterAttribute, BufferLength, StringLength, NumericAttribute);
+ if (iResult == SQL_SUCCESS && CharacterAttribute != NULL && SQLColAttributes_KnownStringAttribute(FieldIdentifier)) {
+ /*
+ TRACE("Dumping values fetched via SQLColAttributeW:\n");
+ TRACE(" Attribute name : %s\n", debugstr_w(rgbDesc));
+ TRACE(" Declared length: %d\n", *pcbDesc);
+ */
+ if (*StringLength != lstrlenW(CharacterAttribute) * 2) {
+ TRACE("CHEAT: resetting name length for ADO\n");
+ *StringLength = lstrlenW(CharacterAttribute) * 2;
+ }
+ }
+ return iResult;
+}
+
+/*************************************************************************
+ * SQLGetConnectAttrW [ODBC32.132]
+ */
+SQLRETURN WINAPI SQLGetConnectAttrW(SQLHDBC ConnectionHandle,
+ SQLINTEGER Attribute, SQLPOINTER Value,
+ SQLINTEGER BufferLength, SQLINTEGER *StringLength)
+{
+ TRACE("\n");
+
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLGETCONNECTATTR].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLGETCONNECTATTR].funcW)
+ (ConnectionHandle, Attribute, Value,
+ BufferLength, StringLength);
+}
+
+/*************************************************************************
+ * SQLGetDescFieldW [ODBC32.133]
+ */
+SQLRETURN WINAPI SQLGetDescFieldW(SQLHDESC DescriptorHandle,
+ SQLSMALLINT RecNumber, SQLSMALLINT FieldIdentifier,
+ SQLPOINTER Value, SQLINTEGER BufferLength,
+ SQLINTEGER *StringLength)
+{
+ TRACE("\n");
+
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLGETDESCFIELD].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLGETDESCFIELD].funcW)
+ (DescriptorHandle, RecNumber, FieldIdentifier,
+ Value, BufferLength, StringLength);
+}
+
+/*************************************************************************
+ * SQLGetDescRecW [ODBC32.134]
+ */
+SQLRETURN WINAPI SQLGetDescRecW(SQLHDESC DescriptorHandle,
+ SQLSMALLINT RecNumber, SQLWCHAR *Name,
+ SQLSMALLINT BufferLength, SQLSMALLINT *StringLength,
+ SQLSMALLINT *Type, SQLSMALLINT *SubType,
+ SQLLEN *Length, SQLSMALLINT *Precision,
+ SQLSMALLINT *Scale, SQLSMALLINT *Nullable)
+{
+ TRACE("\n");
+
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLGETDESCREC].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLGETDESCREC].funcW)
+ (DescriptorHandle, RecNumber, Name, BufferLength,
+ StringLength, Type, SubType, Length, Precision, Scale, Nullable);
+}
+
+/*************************************************************************
+ * SQLGetDiagFieldW [ODBC32.135]
+ */
+SQLRETURN WINAPI SQLGetDiagFieldW(SQLSMALLINT HandleType, SQLHANDLE Handle,
+ SQLSMALLINT RecNumber, SQLSMALLINT DiagIdentifier,
+ SQLPOINTER DiagInfo, SQLSMALLINT BufferLength,
+ SQLSMALLINT *StringLength)
+{
+ TRACE("\n");
+
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLGETDIAGFIELD].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLGETDIAGFIELD].funcW)
+ (HandleType, Handle, RecNumber, DiagIdentifier,
+ DiagInfo, BufferLength, StringLength);
+}
+
+/*************************************************************************
+ * SQLGetDiagRecW [ODBC32.136]
+ */
+SQLRETURN WINAPI SQLGetDiagRecW(SQLSMALLINT HandleType, SQLHANDLE Handle,
+ SQLSMALLINT RecNumber, WCHAR *Sqlstate,
+ SQLINTEGER *NativeError, WCHAR *MessageText,
+ SQLSMALLINT BufferLength, SQLSMALLINT *TextLength)
+{
+ TRACE("\n");
+
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLGETDIAGREC].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLGETDIAGREC].funcW)
+ (HandleType, Handle, RecNumber, Sqlstate, NativeError,
+ MessageText, BufferLength, TextLength);
+}
+
+/*************************************************************************
+ * SQLGetStmtAttrW [ODBC32.138]
+ */
+SQLRETURN WINAPI SQLGetStmtAttrW(SQLHSTMT StatementHandle,
+ SQLINTEGER Attribute, SQLPOINTER Value,
+ SQLINTEGER BufferLength, SQLINTEGER *StringLength)
+{
+ SQLRETURN iResult;
+
+ TRACE("Attribute = (%02ld) Value = %p BufferLength = (%ld) StringLength = %p\n",
+ Attribute, Value, BufferLength, StringLength);
+
+ if (Value == NULL) {
+ WARN("Unexpected NULL in Value return address\n");
+ iResult = SQL_ERROR;
+/*
+ } else if (StringLength == NULL) {
+ WARN("Unexpected NULL in StringLength return address\n");
+ iResult = SQL_ERROR;
+*/
+ } else {
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLGETSTMTATTR].funcW);
+ iResult = (gProxyHandle.functions[SQLAPI_INDEX_SQLGETSTMTATTR].funcW)
+ (StatementHandle, Attribute, Value, BufferLength, StringLength);
+ TRACE("returning %d...\n", iResult);
+ }
+ return iResult;
+}
+
+/*************************************************************************
+ * SQLSetConnectAttrW [ODBC32.139]
+ */
+SQLRETURN WINAPI SQLSetConnectAttrW(SQLHDBC ConnectionHandle, SQLINTEGER Attribute,
+ SQLPOINTER Value, SQLINTEGER StringLength)
+{
+ TRACE("\n");
+
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLSETCONNECTATTR].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLSETCONNECTATTR].funcW)
+ (ConnectionHandle, Attribute, Value, StringLength);
+}
+
+/*************************************************************************
+ * SQLColumnsW [ODBC32.140]
+ */
+SQLRETURN WINAPI SQLColumnsW(SQLHSTMT StatementHandle,
+ WCHAR *CatalogName, SQLSMALLINT NameLength1,
+ WCHAR *SchemaName, SQLSMALLINT NameLength2,
+ WCHAR *TableName, SQLSMALLINT NameLength3,
+ WCHAR *ColumnName, SQLSMALLINT NameLength4)
+{
+ TRACE("\n");
+
+ CHECK_READY_AND_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLCOLUMNS].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLCOLUMNS].funcW)
+ (StatementHandle, CatalogName, NameLength1,
+ SchemaName, NameLength2, TableName, NameLength3, ColumnName, NameLength4);
+}
+
+/*************************************************************************
+ * SQLDriverConnectW [ODBC32.141]
+ */
+SQLRETURN WINAPI SQLDriverConnectW(
+ SQLHDBC hdbc,
+ SQLHWND hwnd,
+ WCHAR *conn_str_in,
+ SQLSMALLINT len_conn_str_in,
+ WCHAR *conn_str_out,
+ SQLSMALLINT conn_str_out_max,
+ SQLSMALLINT *ptr_conn_str_out,
+ SQLUSMALLINT driver_completion )
+{
+ TRACE("ConnStrIn (%d bytes) --> %s\n", len_conn_str_in, debugstr_w(conn_str_in));
+
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLDRIVERCONNECT].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLDRIVERCONNECT].funcW)
+ (hdbc, hwnd, conn_str_in, len_conn_str_in, conn_str_out,
+ conn_str_out_max, ptr_conn_str_out, driver_completion);
+}
+
+/*************************************************************************
+ * SQLGetConnectOptionW [ODBC32.142]
+ */
+SQLRETURN WINAPI SQLGetConnectOptionW(SQLHDBC ConnectionHandle, SQLUSMALLINT Option, SQLPOINTER Value)
+{
+ TRACE("\n");
+
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLGETCONNECTOPTION].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLGETCONNECTOPTION].funcW)
+ (ConnectionHandle, Option, Value);
+}
+
+/*************************************************************************
+ * SQLGetInfoW [ODBC32.145]
+ */
+SQLRETURN WINAPI SQLGetInfoW(SQLHDBC ConnectionHandle,
+ SQLUSMALLINT InfoType, SQLPOINTER InfoValue,
+ SQLSMALLINT BufferLength, SQLSMALLINT *StringLength)
+{
+ SQLRETURN iResult;
+
+ TRACE("InfoType = (%02u), InfoValue = %p, BufferLength = %d bytes\n", InfoType, InfoValue, BufferLength);
+ if (InfoValue == NULL) {
+ WARN("Unexpected NULL in InfoValue address\n");
+ iResult = SQL_ERROR;
+ } else {
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLGETINFO].funcW);
+ iResult = (gProxyHandle.functions[SQLAPI_INDEX_SQLGETINFO].funcW)
+ (ConnectionHandle, InfoType, InfoValue, BufferLength, StringLength);
+ TRACE("returning %d...\n", iResult);
+ }
+ return iResult;
+}
+
+/*************************************************************************
+ * SQLGetTypeInfoW [ODBC32.147]
+ */
+SQLRETURN WINAPI SQLGetTypeInfoW(SQLHSTMT StatementHandle, SQLSMALLINT DataType)
+{
+ TRACE("\n");
+
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLGETTYPEINFO].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLGETTYPEINFO].funcW)
+ (StatementHandle, DataType);
+}
+
+/*************************************************************************
+ * SQLSetConnectOptionW [ODBC32.150]
+ */
+SQLRETURN WINAPI SQLSetConnectOptionW(SQLHDBC ConnectionHandle, SQLUSMALLINT Option, SQLULEN Value)
+{
+ TRACE("\n");
+
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLSETCONNECTOPTION].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLSETCONNECTOPTION].funcW)
+ (ConnectionHandle, Option, Value);
+}
+
+/*************************************************************************
+ * SQLSpecialColumnsW [ODBC32.152]
+ */
+SQLRETURN WINAPI SQLSpecialColumnsW(SQLHSTMT StatementHandle,
+ SQLUSMALLINT IdentifierType, SQLWCHAR *CatalogName,
+ SQLSMALLINT NameLength1, SQLWCHAR *SchemaName,
+ SQLSMALLINT NameLength2, SQLWCHAR *TableName,
+ SQLSMALLINT NameLength3, SQLUSMALLINT Scope,
+ SQLUSMALLINT Nullable)
+{
+
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLSPECIALCOLUMNS].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLSPECIALCOLUMNS].funcW)
+ (StatementHandle, IdentifierType, CatalogName, NameLength1, SchemaName,
+ NameLength2, TableName, NameLength3, Scope, Nullable);
+}
+
+/*************************************************************************
+ * SQLStatisticsW [ODBC32.153]
+ */
+SQLRETURN WINAPI SQLStatisticsW(SQLHSTMT StatementHandle,
+ SQLWCHAR *CatalogName, SQLSMALLINT NameLength1,
+ SQLWCHAR *SchemaName, SQLSMALLINT NameLength2,
+ SQLWCHAR *TableName, SQLSMALLINT NameLength3,
+ SQLUSMALLINT Unique, SQLUSMALLINT Reserved)
+{
+ TRACE("\n");
+
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLSTATISTICS].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLSTATISTICS].funcW)
+ (StatementHandle, CatalogName, NameLength1, SchemaName, NameLength2,
+ TableName, NameLength3, Unique, Reserved);
+}
+
+/*************************************************************************
+ * SQLTablesW [ODBC32.154]
+ */
+SQLRETURN WINAPI SQLTablesW(SQLHSTMT StatementHandle,
+ SQLWCHAR *CatalogName, SQLSMALLINT NameLength1,
+ SQLWCHAR *SchemaName, SQLSMALLINT NameLength2,
+ SQLWCHAR *TableName, SQLSMALLINT NameLength3,
+ SQLWCHAR *TableType, SQLSMALLINT NameLength4)
+{
+ TRACE("\n");
+
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLTABLES].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLTABLES].funcW)
+ (StatementHandle, CatalogName, NameLength1,
+ SchemaName, NameLength2, TableName, NameLength3, TableType, NameLength4);
+}
+
+/*************************************************************************
+ * SQLBrowseConnectW [ODBC32.155]
+ */
+SQLRETURN WINAPI SQLBrowseConnectW(
+ SQLHDBC hdbc,
+ SQLWCHAR *szConnStrIn,
+ SQLSMALLINT cbConnStrIn,
+ SQLWCHAR *szConnStrOut,
+ SQLSMALLINT cbConnStrOutMax,
+ SQLSMALLINT *pcbConnStrOut)
+{
+ TRACE("\n");
+
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLBROWSECONNECT].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLBROWSECONNECT].funcW)
+ (hdbc, szConnStrIn, cbConnStrIn, szConnStrOut, cbConnStrOutMax, pcbConnStrOut);
+}
+
+/*************************************************************************
+ * SQLColumnPrivilegesW [ODBC32.156]
+ */
+SQLRETURN WINAPI SQLColumnPrivilegesW(
+ SQLHSTMT hstmt,
+ SQLWCHAR *szCatalogName,
+ SQLSMALLINT cbCatalogName,
+ SQLWCHAR *szSchemaName,
+ SQLSMALLINT cbSchemaName,
+ SQLWCHAR *szTableName,
+ SQLSMALLINT cbTableName,
+ SQLWCHAR *szColumnName,
+ SQLSMALLINT cbColumnName)
+{
+ TRACE("\n");
+
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLCOLUMNPRIVILEGES].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLCOLUMNPRIVILEGES].funcW)
+ (hstmt, szCatalogName, cbCatalogName, szSchemaName, cbSchemaName,
+ szTableName, cbTableName, szColumnName, cbColumnName);
+}
+
+/*************************************************************************
+ * SQLDataSourcesW [ODBC32.157]
+ */
+SQLRETURN WINAPI SQLDataSourcesW(SQLHENV EnvironmentHandle,
+ SQLUSMALLINT Direction, WCHAR *ServerName,
+ SQLSMALLINT BufferLength1, SQLSMALLINT *NameLength1,
+ WCHAR *Description, SQLSMALLINT BufferLength2,
+ SQLSMALLINT *NameLength2)
+{
+ SQLRETURN ret;
+
+ TRACE("EnvironmentHandle = %p\n", (LPVOID)EnvironmentHandle);
+
+ if (!gProxyHandle.bFunctionReady || gProxyHandle.dmHandle == NULL)
+ {
+ ERR("Error: empty dm handle (gProxyHandle.dmHandle == NULL)\n");
+ return SQL_ERROR;
+ }
+
+ assert(gProxyHandle.functions[SQLAPI_INDEX_SQLDATASOURCES].funcW);
+ ret = (gProxyHandle.functions[SQLAPI_INDEX_SQLDATASOURCES].funcW)
+ (EnvironmentHandle, Direction, ServerName,
+ BufferLength1, NameLength1, Description, BufferLength2, NameLength2);
+
+ if (TRACE_ON(odbc))
+ {
+ TRACE("returns: %d \t", ret);
+ if (*NameLength1 > 0)
+ TRACE("DataSource = %s,", debugstr_w(ServerName));
+ if (*NameLength2 > 0)
+ TRACE(" Description = %s", debugstr_w(Description));
+ TRACE("\n");
+ }
+
+ return ret;
+}
+
+/*************************************************************************
+ * SQLForeignKeysW [ODBC32.160]
+ */
+SQLRETURN WINAPI SQLForeignKeysW(
+ SQLHSTMT hstmt,
+ SQLWCHAR *szPkCatalogName,
+ SQLSMALLINT cbPkCatalogName,
+ SQLWCHAR *szPkSchemaName,
+ SQLSMALLINT cbPkSchemaName,
+ SQLWCHAR *szPkTableName,
+ SQLSMALLINT cbPkTableName,
+ SQLWCHAR *szFkCatalogName,
+ SQLSMALLINT cbFkCatalogName,
+ SQLWCHAR *szFkSchemaName,
+ SQLSMALLINT cbFkSchemaName,
+ SQLWCHAR *szFkTableName,
+ SQLSMALLINT cbFkTableName)
+{
+ TRACE("\n");
+
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLFOREIGNKEYS].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLFOREIGNKEYS].funcW)
+ (hstmt, szPkCatalogName, cbPkCatalogName, szPkSchemaName, cbPkSchemaName,
+ szPkTableName, cbPkTableName, szFkCatalogName, cbFkCatalogName, szFkSchemaName,
+ cbFkSchemaName, szFkTableName, cbFkTableName);
+}
+
+/*************************************************************************
+ * SQLNativeSqlW [ODBC32.162]
+ */
+SQLRETURN WINAPI SQLNativeSqlW(
+ SQLHDBC hdbc,
+ SQLWCHAR *szSqlStrIn,
+ SQLINTEGER cbSqlStrIn,
+ SQLWCHAR *szSqlStr,
+ SQLINTEGER cbSqlStrMax,
+ SQLINTEGER *pcbSqlStr)
+{
+ TRACE("\n");
+
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLNATIVESQL].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLNATIVESQL].funcW)
+ (hdbc, szSqlStrIn, cbSqlStrIn, szSqlStr, cbSqlStrMax, pcbSqlStr);
+}
+
+/*************************************************************************
+ * SQLPrimaryKeysW [ODBC32.165]
+ */
+SQLRETURN WINAPI SQLPrimaryKeysW(
+ SQLHSTMT hstmt,
+ SQLWCHAR *szCatalogName,
+ SQLSMALLINT cbCatalogName,
+ SQLWCHAR *szSchemaName,
+ SQLSMALLINT cbSchemaName,
+ SQLWCHAR *szTableName,
+ SQLSMALLINT cbTableName)
+{
+ TRACE("\n");
+
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLPRIMARYKEYS].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLPRIMARYKEYS].funcW)
+ (hstmt, szCatalogName, cbCatalogName, szSchemaName, cbSchemaName,
+ szTableName, cbTableName);
+}
+
+/*************************************************************************
+ * SQLProcedureColumnsW [ODBC32.166]
+ */
+SQLRETURN WINAPI SQLProcedureColumnsW(
+ SQLHSTMT hstmt,
+ SQLWCHAR *szCatalogName,
+ SQLSMALLINT cbCatalogName,
+ SQLWCHAR *szSchemaName,
+ SQLSMALLINT cbSchemaName,
+ SQLWCHAR *szProcName,
+ SQLSMALLINT cbProcName,
+ SQLWCHAR *szColumnName,
+ SQLSMALLINT cbColumnName)
+{
+ TRACE("\n");
+
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLPROCEDURECOLUMNS].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLPROCEDURECOLUMNS].funcW)
+ (hstmt, szCatalogName, cbCatalogName, szSchemaName, cbSchemaName,
+ szProcName, cbProcName, szColumnName, cbColumnName);
+}
+
+/*************************************************************************
+ * SQLProceduresW [ODBC32.167]
+ */
+SQLRETURN WINAPI SQLProceduresW(
+ SQLHSTMT hstmt,
+ SQLWCHAR *szCatalogName,
+ SQLSMALLINT cbCatalogName,
+ SQLWCHAR *szSchemaName,
+ SQLSMALLINT cbSchemaName,
+ SQLWCHAR *szProcName,
+ SQLSMALLINT cbProcName)
+{
+ TRACE("\n");
+
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLPROCEDURES].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLPROCEDURES].funcW)
+ (hstmt, szCatalogName, cbCatalogName, szSchemaName, cbSchemaName,
+ szProcName, cbProcName);
+}
+
+/*************************************************************************
+ * SQLTablePrivilegesW [ODBC32.170]
+ */
+SQLRETURN WINAPI SQLTablePrivilegesW(
+ SQLHSTMT hstmt,
+ SQLWCHAR *szCatalogName,
+ SQLSMALLINT cbCatalogName,
+ SQLWCHAR *szSchemaName,
+ SQLSMALLINT cbSchemaName,
+ SQLWCHAR *szTableName,
+ SQLSMALLINT cbTableName)
+{
+ TRACE("\n");
+
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLTABLEPRIVILEGES].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLTABLEPRIVILEGES].funcW)
+ (hstmt, szCatalogName, cbCatalogName, szSchemaName, cbSchemaName,
+ szTableName, cbTableName);
+}
+
+/*************************************************************************
+ * SQLDriversW [ODBC32.171]
+ */
+SQLRETURN WINAPI SQLDriversW(
+ SQLHENV henv,
+ SQLUSMALLINT fDirection,
+ SQLWCHAR *szDriverDesc,
+ SQLSMALLINT cbDriverDescMax,
+ SQLSMALLINT *pcbDriverDesc,
+ SQLWCHAR *szDriverAttributes,
+ SQLSMALLINT cbDriverAttrMax,
+ SQLSMALLINT *pcbDriverAttr)
+{
+ TRACE("\n");
+
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLDRIVERS].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLDRIVERS].funcW)
+ (henv, fDirection, szDriverDesc, cbDriverDescMax, pcbDriverDesc,
+ szDriverAttributes, cbDriverAttrMax, pcbDriverAttr);
+}
+
+/*************************************************************************
+ * SQLSetDescFieldW [ODBC32.173]
+ */
+SQLRETURN WINAPI SQLSetDescFieldW(SQLHDESC DescriptorHandle,
+ SQLSMALLINT RecNumber, SQLSMALLINT FieldIdentifier,
+ SQLPOINTER Value, SQLINTEGER BufferLength)
+{
+ TRACE("\n");
+
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLSETDESCFIELD].funcW);
+ return (gProxyHandle.functions[SQLAPI_INDEX_SQLSETDESCFIELD].funcW)
+ (DescriptorHandle, RecNumber, FieldIdentifier, Value, BufferLength);
+}
+
+/*************************************************************************
+ * SQLSetStmtAttrW [ODBC32.176]
+ */
+SQLRETURN WINAPI SQLSetStmtAttrW(SQLHSTMT StatementHandle,
+ SQLINTEGER Attribute, SQLPOINTER Value,
+ SQLINTEGER StringLength)
+{
+ SQLRETURN iResult;
+ TRACE("Attribute = (%02ld) Value = %p StringLength = (%ld)\n",
+ Attribute, Value, StringLength);
+
+ CHECK_dmHandle();
+
+ assert (gProxyHandle.functions[SQLAPI_INDEX_SQLSETSTMTATTR].funcW);
+ iResult = (gProxyHandle.functions[SQLAPI_INDEX_SQLSETSTMTATTR].funcW)
+ (StatementHandle, Attribute, Value, StringLength);
+ if (iResult == SQL_ERROR && (Attribute == SQL_ROWSET_SIZE || Attribute == SQL_ATTR_ROW_ARRAY_SIZE)) {
+ TRACE("CHEAT: returning SQL_SUCCESS to ADO...\n");
+ iResult = SQL_SUCCESS;
+ } else {
+ TRACE("returning %d...\n", iResult);
+ }
+ return iResult;
+}
+
+
/* End of file */
diff --git a/dll/win32/odbc32/proxyodbc.h b/dll/win32/odbc32/proxyodbc.h
index ec884e64248..ee45691eee6 100644
--- a/dll/win32/odbc32/proxyodbc.h
+++ b/dll/win32/odbc32/proxyodbc.h
@@ -33,6 +33,7 @@ typedef struct dm_func /* driver manager functions */
const char *name;
void *d_func;
SQLRETURN (*func)();
+ SQLRETURN (*funcW)();
} DM_FUNC;
typedef struct proxyhandle
@@ -44,7 +45,6 @@ typedef struct proxyhandle
int nErrorType;
DM_FUNC functions[NUM_SQLFUNC]; /* entry point for driver manager functions */
char driverLibName[200]; /* ODBC driver SO name */
- char dmLibName[200]; /* driver manager library name */
char ServerName[200]; /* keep server name */
char UserName[50]; /* keep username */
} PROXYHANDLE;
diff --git a/dll/win32/win32.rbuild b/dll/win32/win32.rbuild
index ad862f5169e..02b8f89475d 100644
--- a/dll/win32/win32.rbuild
+++ b/dll/win32/win32.rbuild
@@ -334,6 +334,9 @@
+
+
+
diff --git a/drivers/network/ndis/ndis/time.c b/drivers/network/ndis/ndis/time.c
index 0e8cdd46473..eb5d00579c4 100644
--- a/drivers/network/ndis/ndis/time.c
+++ b/drivers/network/ndis/ndis/time.c
@@ -170,11 +170,6 @@ MiniTimerDpcFunction(PKDPC Dpc,
{
PNDIS_MINIPORT_TIMER Timer = DeferredContext;
- Timer->MiniportTimerFunction(Dpc,
- Timer->MiniportTimerContext,
- SystemArgument1,
- SystemArgument2);
-
/* Only dequeue if the timer has a period of 0 */
if (!Timer->Timer.Period)
{
@@ -183,6 +178,11 @@ MiniTimerDpcFunction(PKDPC Dpc,
if (!DequeueMiniportTimer(Timer)) ASSERT(FALSE);
KeReleaseSpinLockFromDpcLevel(&Timer->Miniport->Lock);
}
+
+ Timer->MiniportTimerFunction(Dpc,
+ Timer->MiniportTimerContext,
+ SystemArgument1,
+ SystemArgument2);
}
diff --git a/drivers/wdm/audio/backpln/portcls/api.cpp b/drivers/wdm/audio/backpln/portcls/api.cpp
index e890e751334..1c0fca303d8 100644
--- a/drivers/wdm/audio/backpln/portcls/api.cpp
+++ b/drivers/wdm/audio/backpln/portcls/api.cpp
@@ -108,7 +108,7 @@ PcRegisterIoTimeout(
{
bFound = TRUE;
Status = STATUS_UNSUCCESSFUL;
- ExFreePool(TimerContext);
+ FreeItem(TimerContext, TAG_PORTCLASS);
break;
}
ListEntry = ListEntry->Flink;
@@ -161,7 +161,7 @@ PcUnregisterIoTimeout(
{
bFound = TRUE;
RemoveEntryList(&CurContext->Entry);
- ExFreePool(CurContext);
+ FreeItem(CurContext, TAG_PORTCLASS);
break;
}
ListEntry = ListEntry->Flink;
@@ -196,7 +196,7 @@ PcCompletePendingPropertyRequest(
IoCompleteRequest(PropertyRequest->Irp, IO_SOUND_INCREMENT);
// free the property request
- ExFreePool(PropertyRequest);
+ FreeItem(PropertyRequest, TAG_PORTCLASS);
// return success
return STATUS_SUCCESS;
diff --git a/drivers/wdm/audio/backpln/portcls/connection.cpp b/drivers/wdm/audio/backpln/portcls/connection.cpp
index 4b5276f9f6c..b2ce12df612 100644
--- a/drivers/wdm/audio/backpln/portcls/connection.cpp
+++ b/drivers/wdm/audio/backpln/portcls/connection.cpp
@@ -207,7 +207,7 @@ RegisterConnection(
if (FromSubDeviceDescriptor)
{
- FromEntry = (PPHYSICAL_CONNECTION_ENTRY)AllocateItem(NonPagedPool, sizeof(PHYSICAL_CONNECTION_ENTRY) + ToString->MaximumLength, TAG_PORTCLASS);
+ FromEntry = (PPHYSICAL_CONNECTION_ENTRY)AllocateItem(NonPagedPool, sizeof(PHYSICAL_CONNECTION_ENTRY) + ToString->MaximumLength + sizeof(WCHAR), TAG_PORTCLASS);
if (!FromEntry)
{
Status = STATUS_INSUFFICIENT_RESOURCES;
@@ -217,7 +217,7 @@ RegisterConnection(
if (ToSubDeviceDescriptor)
{
- ToEntry = (PPHYSICAL_CONNECTION_ENTRY)AllocateItem(NonPagedPool, sizeof(PHYSICAL_CONNECTION_ENTRY) + FromString->MaximumLength, TAG_PORTCLASS);
+ ToEntry = (PPHYSICAL_CONNECTION_ENTRY)AllocateItem(NonPagedPool, sizeof(PHYSICAL_CONNECTION_ENTRY) + FromString->MaximumLength + sizeof(WCHAR), TAG_PORTCLASS);
if (!ToEntry)
{
Status = STATUS_INSUFFICIENT_RESOURCES;
@@ -229,9 +229,9 @@ RegisterConnection(
{
FromEntry->FromPin = FromPin;
FromEntry->Connection.Pin = ToPin;
- FromEntry->Connection.Size = sizeof(KSPIN_PHYSICALCONNECTION) + ToString->MaximumLength;
+ FromEntry->Connection.Size = sizeof(KSPIN_PHYSICALCONNECTION) + ToString->MaximumLength + sizeof(WCHAR);
RtlMoveMemory(&FromEntry->Connection.SymbolicLinkName, ToString->Buffer, ToString->MaximumLength);
- FromEntry->Connection.SymbolicLinkName[ToString->Length / sizeof(WCHAR)] = L'\0';
+ FromEntry->Connection.SymbolicLinkName[ToString->Length / sizeof(WCHAR)] = UNICODE_NULL;
InsertTailList(&FromSubDeviceDescriptor->PhysicalConnectionList, &FromEntry->Entry);
}
@@ -241,9 +241,9 @@ RegisterConnection(
{
ToEntry->FromPin = ToPin;
ToEntry->Connection.Pin = FromPin;
- ToEntry->Connection.Size = sizeof(KSPIN_PHYSICALCONNECTION) + FromString->MaximumLength;
+ ToEntry->Connection.Size = sizeof(KSPIN_PHYSICALCONNECTION) + FromString->MaximumLength + sizeof(WCHAR);
RtlMoveMemory(&ToEntry->Connection.SymbolicLinkName, FromString->Buffer, FromString->MaximumLength);
- ToEntry->Connection.SymbolicLinkName[FromString->Length / sizeof(WCHAR)] = L'\0';
+ ToEntry->Connection.SymbolicLinkName[FromString->Length / sizeof(WCHAR)] = UNICODE_NULL;
InsertTailList(&ToSubDeviceDescriptor->PhysicalConnectionList, &ToEntry->Entry);
diff --git a/drivers/wdm/audio/backpln/portcls/interrupt.cpp b/drivers/wdm/audio/backpln/portcls/interrupt.cpp
index a0c78ad9f21..af4b0c18cdf 100644
--- a/drivers/wdm/audio/backpln/portcls/interrupt.cpp
+++ b/drivers/wdm/audio/backpln/portcls/interrupt.cpp
@@ -234,7 +234,7 @@ CInterruptSync::Connect()
DPRINT("Vector %u Level %u Flags %x Affinity %x\n", Descriptor->u.Interrupt.Vector, Descriptor->u.Interrupt.Level, Descriptor->Flags, Descriptor->u.Interrupt.Affinity);
- Status = IoConnectInterrupt(&m_Interrupt,
+ Status = IoConnectInterrupt(&m_Interrupt,
IInterruptServiceRoutine,
(PVOID)this,
&m_Lock,
diff --git a/drivers/wdm/audio/backpln/portcls/pin_dmus.cpp b/drivers/wdm/audio/backpln/portcls/pin_dmus.cpp
index 991e0e11426..4bcad8c49d0 100644
--- a/drivers/wdm/audio/backpln/portcls/pin_dmus.cpp
+++ b/drivers/wdm/audio/backpln/portcls/pin_dmus.cpp
@@ -427,7 +427,7 @@ CPortPinDMus::Close(
if (m_Format)
{
- ExFreePool(m_Format);
+ FreeItem(m_Format, TAG_PORTCLASS);
m_Format = NULL;
}
diff --git a/drivers/wdm/audio/backpln/portcls/pin_wavecyclic.cpp b/drivers/wdm/audio/backpln/portcls/pin_wavecyclic.cpp
index 0520480ae92..003b9b339cd 100644
--- a/drivers/wdm/audio/backpln/portcls/pin_wavecyclic.cpp
+++ b/drivers/wdm/audio/backpln/portcls/pin_wavecyclic.cpp
@@ -959,7 +959,7 @@ CPortPinWaveCyclic::Close(
if (m_Format)
{
// free format
- ExFreePool(m_Format);
+ FreeItem(m_Format, TAG_PORTCLASS);
m_Format = NULL;
}
@@ -1222,6 +1222,10 @@ CPortPinWaveCyclic::Init(
// delay of 10 milisec
m_Delay = Int32x32To64(10, -10000);
+ // sanity checks
+ PC_ASSERT(m_CommonBufferSize);
+ PC_ASSERT(m_CommonBuffer);
+
Status = m_Stream->SetNotificationFreq(10, &m_FrameSize);
PC_ASSERT(NT_SUCCESS(Status));
PC_ASSERT(m_FrameSize);
diff --git a/drivers/wdm/audio/backpln/portcls/pin_wavepci.cpp b/drivers/wdm/audio/backpln/portcls/pin_wavepci.cpp
index 1b44fe1794f..69985c59d42 100644
--- a/drivers/wdm/audio/backpln/portcls/pin_wavepci.cpp
+++ b/drivers/wdm/audio/backpln/portcls/pin_wavepci.cpp
@@ -668,7 +668,7 @@ CPortPinWavePci::Close(
if (m_Format)
{
- ExFreePool(m_Format);
+ FreeItem(m_Format, TAG_PORTCLASS);
m_Format = NULL;
}
diff --git a/drivers/wdm/audio/backpln/portcls/pin_wavert.cpp b/drivers/wdm/audio/backpln/portcls/pin_wavert.cpp
index 0aa281d0032..7c3d0367123 100644
--- a/drivers/wdm/audio/backpln/portcls/pin_wavert.cpp
+++ b/drivers/wdm/audio/backpln/portcls/pin_wavert.cpp
@@ -226,7 +226,7 @@ CPortPinWaveRT::HandleKsProperty(
if (NT_SUCCESS(Status))
{
if (m_Format)
- ExFreePoolWithTag(m_Format, TAG_PORTCLASS);
+ FreeItem(m_Format, TAG_PORTCLASS);
m_Format = NewDataFormat;
Irp->IoStatus.Information = DataFormat->FormatSize;
@@ -400,7 +400,7 @@ CloseStreamRoutine(
if (This->m_Format)
{
- ExFreePool(This->m_Format);
+ FreeItem(This->m_Format, TAG_PORTCLASS);
This->m_Format = NULL;
}
diff --git a/drivers/wdm/audio/backpln/portcls/port_wavepci.cpp b/drivers/wdm/audio/backpln/portcls/port_wavepci.cpp
index 986ffcf9d40..7e55116e52c 100644
--- a/drivers/wdm/audio/backpln/portcls/port_wavepci.cpp
+++ b/drivers/wdm/audio/backpln/portcls/port_wavepci.cpp
@@ -187,6 +187,11 @@ CPortWavePci::QueryInterface(
PUNKNOWN(*Output)->AddRef();
return STATUS_SUCCESS;
}
+ else if (IsEqualGUIDAligned(refiid, IID_IDrmPort) ||
+ IsEqualGUIDAligned(refiid, IID_IDrmPort2))
+ {
+ return NewIDrmPort((PDRMPORT2*)Output);
+ }
else if (IsEqualGUIDAligned(refiid, IID_IPortClsVersion))
{
return NewPortClsVersion((PPORTCLSVERSION*)Output);
@@ -251,8 +256,13 @@ CPortWavePci::Init(
// increment reference on miniport adapter
Miniport->AddRef();
- // increment reference on resource list
- ResourceList->AddRef();
+
+
+ if (ResourceList)
+ {
+ // increment reference on resource list
+ ResourceList->AddRef();
+ }
Status = Miniport->Init(UnknownAdapter, ResourceList, this, &ServiceGroup);
if (!NT_SUCCESS(Status))
diff --git a/drivers/wdm/audio/backpln/portcls/resource.cpp b/drivers/wdm/audio/backpln/portcls/resource.cpp
index 926e999870d..181ca10d862 100644
--- a/drivers/wdm/audio/backpln/portcls/resource.cpp
+++ b/drivers/wdm/audio/backpln/portcls/resource.cpp
@@ -438,8 +438,8 @@ PcNewResourceSublist(
Parent = (CResourceList*)ParentList;
- if (!Parent->m_TranslatedResourceList->List->PartialResourceList.Count ||
- !Parent->m_UntranslatedResourceList->List->PartialResourceList.Count)
+ if (!Parent->m_TranslatedResourceList->List[0].PartialResourceList.Count ||
+ !Parent->m_UntranslatedResourceList->List[0].PartialResourceList.Count)
{
// parent list can't be empty
return STATUS_INVALID_PARAMETER;
@@ -467,8 +467,8 @@ PcNewResourceSublist(
RtlCopyMemory(NewList->m_UntranslatedResourceList, Parent->m_UntranslatedResourceList, sizeof(CM_RESOURCE_LIST));
// mark list as empty
- NewList->m_TranslatedResourceList->List->PartialResourceList.Count = 0;
- NewList->m_UntranslatedResourceList->List->PartialResourceList.Count = 0;
+ NewList->m_TranslatedResourceList->List[0].PartialResourceList.Count = 0;
+ NewList->m_UntranslatedResourceList->List[0].PartialResourceList.Count = 0;
// store members
NewList->m_OuterUnknown = OuterUnknown;
NewList->m_PoolType = PoolType;
diff --git a/drivers/wdm/audio/sysaudio/control.c b/drivers/wdm/audio/sysaudio/control.c
index 6a2466c46cc..459065ac8b1 100644
--- a/drivers/wdm/audio/sysaudio/control.c
+++ b/drivers/wdm/audio/sysaudio/control.c
@@ -145,7 +145,7 @@ ComputeCompatibleFormat(
ULONG Index;
Length = sizeof(KSP_PIN) + sizeof(KSMULTIPLE_ITEM) + ClientFormat->DataFormat.FormatSize;
- PinRequest = ExAllocatePool(NonPagedPool, Length);
+ PinRequest = AllocateItem(NonPagedPool, Length);
if (!PinRequest)
return STATUS_UNSUCCESSFUL;
@@ -166,7 +166,7 @@ ComputeCompatibleFormat(
if (NT_SUCCESS(Status))
{
- ExFreePool(PinRequest);
+ FreeItem(PinRequest);
return Status;
}
@@ -181,10 +181,10 @@ ComputeCompatibleFormat(
return Status;
}
- MultipleItem = ExAllocatePool(NonPagedPool, BytesReturned);
+ MultipleItem = AllocateItem(NonPagedPool, BytesReturned);
if (!MultipleItem)
{
- ExFreePool(PinRequest);
+ FreeItem(PinRequest);
return STATUS_NO_MEMORY;
}
@@ -192,8 +192,8 @@ ComputeCompatibleFormat(
if (!NT_SUCCESS(Status))
{
DPRINT("Property Request KSPROPERTY_PIN_DATARANGES failed with %x\n", Status);
- ExFreePool(MultipleItem);
- ExFreePool(PinRequest);
+ FreeItem(MultipleItem);
+ FreeItem(PinRequest);
return STATUS_UNSUCCESSFUL;
}
@@ -253,8 +253,8 @@ ComputeCompatibleFormat(
#endif
- ExFreePool(MultipleItem);
- ExFreePool(PinRequest);
+ FreeItem(MultipleItem);
+ FreeItem(PinRequest);
if (bFound)
return STATUS_SUCCESS;
diff --git a/drivers/wdm/audio/sysaudio/deviface.c b/drivers/wdm/audio/sysaudio/deviface.c
index e1a0cfeaf04..605946c300c 100644
--- a/drivers/wdm/audio/sysaudio/deviface.c
+++ b/drivers/wdm/audio/sysaudio/deviface.c
@@ -70,7 +70,7 @@ InsertAudioDevice(
PKSAUDIO_DEVICE_ENTRY DeviceEntry = NULL;
/* a new device has arrived */
- DeviceEntry = ExAllocatePool(NonPagedPool, sizeof(KSAUDIO_DEVICE_ENTRY));
+ DeviceEntry = AllocateItem(NonPagedPool, sizeof(KSAUDIO_DEVICE_ENTRY));
if (!DeviceEntry)
{
/* no memory */
@@ -84,7 +84,7 @@ InsertAudioDevice(
DeviceEntry->DeviceName.Length = 0;
DeviceEntry->DeviceName.MaximumLength = DeviceName->MaximumLength + 10 * sizeof(WCHAR);
- DeviceEntry->DeviceName.Buffer = ExAllocatePool(NonPagedPool, DeviceEntry->DeviceName.MaximumLength);
+ DeviceEntry->DeviceName.Buffer = AllocateItem(NonPagedPool, DeviceEntry->DeviceName.MaximumLength);
if (!DeviceEntry->DeviceName.Buffer)
{
@@ -115,9 +115,9 @@ cleanup:
if (DeviceEntry)
{
if (DeviceEntry->DeviceName.Buffer)
- ExFreePool(DeviceEntry->DeviceName.Buffer);
+ FreeItem(DeviceEntry->DeviceName.Buffer);
- ExFreePool(DeviceEntry);
+ FreeItem(DeviceEntry);
}
return Status;
diff --git a/drivers/wdm/audio/sysaudio/dispatcher.c b/drivers/wdm/audio/sysaudio/dispatcher.c
index e29b8b4d936..6c0f58de983 100644
--- a/drivers/wdm/audio/sysaudio/dispatcher.c
+++ b/drivers/wdm/audio/sysaudio/dispatcher.c
@@ -70,7 +70,7 @@ DispatchCreateSysAudio(
DPRINT("DispatchCreateSysAudio entered\n");
/* allocate create item */
- CreateItem = ExAllocatePool(NonPagedPool, sizeof(KSOBJECT_CREATE_ITEM));
+ CreateItem = AllocateItem(NonPagedPool, sizeof(KSOBJECT_CREATE_ITEM));
if (!CreateItem)
{
Irp->IoStatus.Information = 0;
@@ -105,7 +105,7 @@ SysAudioAllocateDeviceHeader(
PKSOBJECT_CREATE_ITEM CreateItem;
/* allocate create item */
- CreateItem = ExAllocatePool(NonPagedPool, sizeof(KSOBJECT_CREATE_ITEM));
+ CreateItem = AllocateItem(NonPagedPool, sizeof(KSOBJECT_CREATE_ITEM));
if (!CreateItem)
return STATUS_INSUFFICIENT_RESOURCES;
diff --git a/drivers/wdm/audio/sysaudio/main.c b/drivers/wdm/audio/sysaudio/main.c
index de1e06e3ce4..2df6f55a84b 100644
--- a/drivers/wdm/audio/sysaudio/main.c
+++ b/drivers/wdm/audio/sysaudio/main.c
@@ -18,6 +18,25 @@ const GUID KSCATEGORY_PREFERRED_WAVEOUT_DEVICE = {0xD6C5066EL, 0x72C1, 0x11D2, {
const GUID KSCATEGORY_PREFERRED_WAVEIN_DEVICE = {0xD6C50671L, 0x72C1, 0x11D2, {0x97, 0x55, 0x00, 0x00, 0xF8, 0x00, 0x47, 0x88}};
const GUID KSCATEGORY_PREFERRED_MIDIOUT_DEVICE = {0xD6C50674L, 0x72C1, 0x11D2, {0x97, 0x55, 0x00, 0x00, 0xF8, 0x00, 0x47, 0x88}};
+PVOID
+AllocateItem(
+ IN POOL_TYPE PoolType,
+ IN SIZE_T NumberOfBytes)
+{
+ PVOID Item = ExAllocatePool(PoolType, NumberOfBytes);
+ if (!Item)
+ return Item;
+
+ RtlZeroMemory(Item, NumberOfBytes);
+ return Item;
+}
+
+VOID
+FreeItem(
+ IN PVOID Item)
+{
+ ExFreePool(Item);
+}
VOID
@@ -58,7 +77,7 @@ SysAudio_Shutdown(
RtlFreeUnicodeString(&DeviceEntry->DeviceName);
/* free audio device entry */
- ExFreePool(DeviceEntry);
+ FreeItem(DeviceEntry);
}
Irp->IoStatus.Information = 0;
diff --git a/drivers/wdm/audio/sysaudio/pin.c b/drivers/wdm/audio/sysaudio/pin.c
index 36ce635708d..eb5ee6177e0 100644
--- a/drivers/wdm/audio/sysaudio/pin.c
+++ b/drivers/wdm/audio/sysaudio/pin.c
@@ -149,7 +149,7 @@ Pin_fnClose(
ZwClose(Context->hMixerPin);
}
- ExFreePool(Context);
+ FreeItem(Context);
Irp->IoStatus.Status = STATUS_SUCCESS;
Irp->IoStatus.Information = 0;
@@ -315,7 +315,7 @@ InstantiatePins(
/* the audio irp pin didnt accept the input format
* let's compute a compatible format
*/
- MixerPinConnect = ExAllocatePool(NonPagedPool, sizeof(KSPIN_CONNECT) + sizeof(KSDATAFORMAT_WAVEFORMATEX));
+ MixerPinConnect = AllocateItem(NonPagedPool, sizeof(KSPIN_CONNECT) + sizeof(KSDATAFORMAT_WAVEFORMATEX));
if (!MixerPinConnect)
{
/* not enough memory */
@@ -335,7 +335,7 @@ InstantiatePins(
if (!NT_SUCCESS(Status))
{
DPRINT1("ComputeCompatibleFormat failed with %x\n", Status);
- ExFreePool(MixerPinConnect);
+ FreeItem(MixerPinConnect);
return Status;
}
@@ -348,7 +348,7 @@ InstantiatePins(
DPRINT1(" InputFormat: SampleRate %u Bits %u Channels %u\n", InputFormat->WaveFormatEx.nSamplesPerSec, InputFormat->WaveFormatEx.wBitsPerSample, InputFormat->WaveFormatEx.nChannels);
DPRINT1("OutputFormat: SampleRate %u Bits %u Channels %u\n", OutputFormat->WaveFormatEx.nSamplesPerSec, OutputFormat->WaveFormatEx.wBitsPerSample, OutputFormat->WaveFormatEx.nChannels);
- ExFreePool(MixerPinConnect);
+ FreeItem(MixerPinConnect);
return Status;
}
}
@@ -378,7 +378,7 @@ InstantiatePins(
if (!NT_SUCCESS(Status))
{
DPRINT1("Failed to create Mixer Pin with %x\n", Status);
- ExFreePool(MixerPinConnect);
+ FreeItem(MixerPinConnect);
}
}
/* done */
@@ -408,7 +408,7 @@ GetConnectRequest(
ParametersLength = IoStack->FileObject->FileName.MaximumLength - ObjectLength;
/* allocate buffer */
- Buffer = ExAllocatePool(NonPagedPool, ParametersLength);
+ Buffer = AllocateItem(NonPagedPool, ParametersLength);
if (!Buffer)
return STATUS_INSUFFICIENT_RESOURCES;
@@ -471,7 +471,7 @@ DispatchCreateSysAudioPin(
/* allocate dispatch context */
- DispatchContext = ExAllocatePool(NonPagedPool, sizeof(DISPATCH_CONTEXT));
+ DispatchContext = AllocateItem(NonPagedPool, sizeof(DISPATCH_CONTEXT));
if (!DispatchContext)
{
/* failed */
@@ -488,7 +488,7 @@ DispatchCreateSysAudioPin(
if (!NT_SUCCESS(Status))
{
/* failed */
- ExFreePool(DispatchContext);
+ FreeItem(DispatchContext);
Irp->IoStatus.Status = Status;
IoCompleteRequest(Irp, IO_NO_INCREMENT);
return Status;
@@ -500,7 +500,7 @@ DispatchCreateSysAudioPin(
{
/* failed */
KsFreeObjectHeader(DispatchContext->ObjectHeader);
- ExFreePool(DispatchContext);
+ FreeItem(DispatchContext);
}
else
{
diff --git a/drivers/wdm/audio/sysaudio/sysaudio.h b/drivers/wdm/audio/sysaudio/sysaudio.h
index e5c11208dbf..bd8aea38d83 100644
--- a/drivers/wdm/audio/sysaudio/sysaudio.h
+++ b/drivers/wdm/audio/sysaudio/sysaudio.h
@@ -116,3 +116,13 @@ ComputeCompatibleFormat(
IN ULONG PinId,
IN PKSDATAFORMAT_WAVEFORMATEX ClientFormat,
OUT PKSDATAFORMAT_WAVEFORMATEX MixerFormat);
+
+PVOID
+AllocateItem(
+ IN POOL_TYPE PoolType,
+ IN SIZE_T NumberOfBytes);
+
+VOID
+FreeItem(
+ IN PVOID Item);
+
diff --git a/include/reactos/mc/mc.rbuild b/include/reactos/mc/mc.rbuild
index eb06ec499ca..ab96b18c98b 100644
--- a/include/reactos/mc/mc.rbuild
+++ b/include/reactos/mc/mc.rbuild
@@ -12,4 +12,8 @@
errcodes.mc
+
+
+ netevent.mc
+
\ No newline at end of file
diff --git a/include/reactos/mc/netevent.mc b/include/reactos/mc/netevent.mc
new file mode 100644
index 00000000000..6c15a3466c4
--- /dev/null
+++ b/include/reactos/mc/netevent.mc
@@ -0,0 +1,68 @@
+;
+; netevent.mc MESSAGE resources for netevent.dll
+;
+
+MessageIdTypedef=DWORD
+
+SeverityNames=(Success=0x0:STATUS_SEVERITY_SUCCESS
+ Informational=0x1:STATUS_SEVERITY_INFORMATIONAL
+ Warning=0x2:STATUS_SEVERITY_WARNING
+ Error=0x3:STATUS_SEVERITY_ERROR
+ )
+
+FacilityNames=(System=0x0:FACILITY_SYSTEM
+ )
+
+LanguageNames=(English=0x409:MSG00409)
+
+
+;
+; message definitions
+;
+
+; Facility=System
+
+; Eventlog messages 6xxx-
+
+MessageId=6005
+Severity=Warning
+Facility=System
+SymbolicName=EVENT_EventlogStarted
+Language=English
+The Event log service was started.
+.
+
+MessageId=6006
+Severity=Warning
+Facility=System
+SymbolicName=EVENT_EventlogStopped
+Language=English
+The Event log service was stopped.
+.
+
+MessageId=6009
+Severity=Warning
+Facility=System
+SymbolicName=EVENT_EventlogProductInfo
+Language=English
+ReactOS %1 %2 %3 %4.
+.
+
+
+; transport messages
+
+MessageId=9004
+Severity=Error
+Facility=System
+SymbolicName=EVENT_TRANSPORT_REGISTER_FAILED
+Language=English
+%2 failed to register itself with the NDIS wrapper.
+.
+
+MessageId=9006
+Severity=Error
+Facility=System
+SymbolicName=EVENT_TRANSPORT_ADAPTER_NOT_FOUND
+Language=English
+%2 could not find adapter %3.
+.
diff --git a/lib/drivers/oskittcp/include/freebsd/src/sys/machine/endian.h b/lib/drivers/oskittcp/include/freebsd/src/sys/machine/endian.h
index bf687d22af2..0aeb4ad5f19 100644
--- a/lib/drivers/oskittcp/include/freebsd/src/sys/machine/endian.h
+++ b/lib/drivers/oskittcp/include/freebsd/src/sys/machine/endian.h
@@ -56,61 +56,8 @@
#include
#endif
-#ifdef _MSC_VER
-static inline unsigned long __byte_swap_long ( unsigned long i )
-{
- char dst[4];
- char* src = (char*)&i;
- dst[0] = src[3];
- dst[1] = src[2];
- dst[2] = src[1];
- dst[3] = src[0];
- return *(unsigned long*)&dst[0];
-}
-
-static inline unsigned short __byte_swap_word ( unsigned short i )
-{
- char dst[2];
- char* src = (char*)&i;
- dst[0] = src[1];
- dst[1] = src[0];
- return *(unsigned short*)&dst[0];
-}
-#else/*_MSC_VER*/
-#define __word_swap_long(x) \
-({ register u_long __X = (x); \
- __asm ("rorl $16, %1" \
- : "=r" (__X) \
- : "0" (__X)); \
- __X; })
-#if __GNUC__ >= 2
-#define __byte_swap_long(x) \
-__extension__ ({ register u_long __X = (x); \
- __asm ("xchgb %h1, %b1\n\trorl $16, %1\n\txchgb %h1, %b1" \
- : "=q" (__X) \
- : "0" (__X)); \
- __X; })
-#define __byte_swap_word(x) \
-__extension__ ({ register u_short __X = (x); \
- __asm ("xchgb %h1, %b1" \
- : "=q" (__X) \
- : "0" (__X)); \
- __X; })
-#else /* __GNUC__ >= 2 */
-#define __byte_swap_long(x) \
-({ register u_long __X = (x); \
- __asm ("rorw $8, %w1\n\trorl $16, %1\n\trorw $8, %w1" \
- : "=r" (__X) \
- : "0" (__X)); \
- __X; })
-#define __byte_swap_word(x) \
-({ register u_short __X = (x); \
- __asm ("rorw $8, %w1" \
- : "=r" (__X) \
- : "0" (__X)); \
- __X; })
-#endif /* __GNUC__ >= 2 */
-#endif /* _MSC_VER */
+#define __byte_swap_long RtlUlongByteSwap
+#define __byte_swap_word RtlUshortByteSwap
/*
* Macros for network/external number representation conversion.
diff --git a/lib/sdk/crt/crt.rbuild b/lib/sdk/crt/crt.rbuild
index 0fd49d12b1c..7b4bc6fdc72 100644
--- a/lib/sdk/crt/crt.rbuild
+++ b/lib/sdk/crt/crt.rbuild
@@ -329,7 +329,6 @@
gcvt.c
getenv.c
makepath.c
- malloc.c
mbtowc.c
mbstowcs.c
obsol.c
diff --git a/lib/sdk/crt/float/i386/cntrlfp.c b/lib/sdk/crt/float/i386/cntrlfp.c
index 2cc46d8bf4b..75d5c0ad829 100644
--- a/lib/sdk/crt/float/i386/cntrlfp.c
+++ b/lib/sdk/crt/float/i386/cntrlfp.c
@@ -104,3 +104,25 @@ unsigned int CDECL _control87(unsigned int newval, unsigned int mask)
return flags;
}
+
+/*********************************************************************
+ * _controlfp_s (MSVCRT.@)
+ */
+int CDECL _controlfp_s(unsigned int *cur, unsigned int newval, unsigned int mask)
+{
+#ifdef __i386__
+ unsigned int flags;
+
+ FIXME("(%p %u %u) semi-stub\n", cur, newval, mask);
+
+ flags = _control87( newval, mask & ~_EM_DENORMAL );
+
+ if(cur)
+ *cur = flags;
+
+ return 0;
+#else
+ FIXME(":Not Implemented!\n");
+ return 0;
+#endif
+}
diff --git a/lib/sdk/crt/math/rand.c b/lib/sdk/crt/math/rand.c
index f788ecf72ab..4d560a2aac4 100644
--- a/lib/sdk/crt/math/rand.c
+++ b/lib/sdk/crt/math/rand.c
@@ -1,6 +1,6 @@
/* Copyright (C) 1994 DJ Delorie, see COPYING.DJ for details */
#include
-
+//#include
#include
/*
@@ -25,3 +25,18 @@ srand(unsigned int seed)
ThreadData->tnext = (ULONGLONG)seed;
}
+
+ /*********************************************************************
+ * rand_s (MSVCRT.@)
+ */
+int CDECL rand_s(unsigned int *pval)
+{
+#if 0
+ if (!pval || !RtlGenRandom(pval, sizeof(*pval)))
+ {
+ *_errno() = EINVAL;
+ return EINVAL;
+ }
+#endif
+ return 0;
+}
diff --git a/lib/sdk/crt/misc/stubs.c b/lib/sdk/crt/misc/stubs.c
index 00f4a2b0300..7eac2b0fef9 100644
--- a/lib/sdk/crt/misc/stubs.c
+++ b/lib/sdk/crt/misc/stubs.c
@@ -15,11 +15,6 @@ void MSVCRT_I10_OUTPUT(void)
/* FIXME: This is probably data, not a function */
}
-void __p__amblksiz(void)
-{
- FIXME("__p__amblksiz stub\n");
-}
-
void __fileinfo(void)
{
FIXME("__fileinfo stub\n");
diff --git a/lib/sdk/crt/stdlib/errno.c b/lib/sdk/crt/stdlib/errno.c
index 3a8d76e1be6..6cbd20acb18 100644
--- a/lib/sdk/crt/stdlib/errno.c
+++ b/lib/sdk/crt/stdlib/errno.c
@@ -8,8 +8,11 @@
*/
#include
#include "doserrmap.h"
+#include
#include
+static _invalid_parameter_handler invalid_parameter_handler = NULL;
+
/*
* @implemented
*/
@@ -113,4 +116,36 @@ void CDECL _seterrormode(int mode)
SetErrorMode( mode );
}
+/******************************************************************************
+ * _invalid_parameter (MSVCRT.@)
+ */
+void __cdecl _invalid_parameter(const wchar_t *expr, const wchar_t *func,
+ const wchar_t *file, unsigned int line, uintptr_t arg)
+{
+ if (invalid_parameter_handler) invalid_parameter_handler( expr, func, file, line, arg );
+ else
+ {
+ ERR( "%s:%u %s: %s %lx\n", debugstr_w(file), line, debugstr_w(func), debugstr_w(expr), arg );
+ RaiseException( STATUS_INVALID_CRUNTIME_PARAMETER, EXCEPTION_NONCONTINUABLE, 0, NULL );
+ }
+}
+
+/* _get_invalid_parameter_handler - not exported in native msvcrt, added in msvcr80 */
+_invalid_parameter_handler CDECL _get_invalid_parameter_handler(void)
+{
+ TRACE("\n");
+ return invalid_parameter_handler;
+}
+
+/* _set_invalid_parameter_handler - not exproted in native msvcrt, added in msvcr80 */
+_invalid_parameter_handler CDECL _set_invalid_parameter_handler(
+ _invalid_parameter_handler handler)
+{
+ _invalid_parameter_handler old = invalid_parameter_handler;
+
+ TRACE("(%p)\n", handler);
+
+ invalid_parameter_handler = handler;
+ return old;
+}
/* EOF */
diff --git a/lib/sdk/crt/wine/heap.c b/lib/sdk/crt/wine/heap.c
index daabff8babb..08973706c2b 100644
--- a/lib/sdk/crt/wine/heap.c
+++ b/lib/sdk/crt/wine/heap.c
@@ -15,13 +15,14 @@
*
* 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
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*
* Note: Win32 heap operations are MT safe. We only lock the new
* handler and non atomic heap operations
*/
#include
+#include
/* MT */
#define LOCK_HEAP _mlock( _HEAP_LOCK )
@@ -29,47 +30,60 @@
/* _aligned */
#define SAVED_PTR(x) ((void *)((DWORD_PTR)((char *)x - sizeof(void *)) & \
- ~(sizeof(void *) - 1)))
+ ~(sizeof(void *) - 1)))
#define ALIGN_PTR(ptr, alignment, offset) ((void *) \
((((DWORD_PTR)((char *)ptr + alignment + sizeof(void *) + offset)) & \
~(alignment - 1)) - offset))
-typedef void (*MSVCRT_new_handler_func)(unsigned long size);
+typedef void (*MSVCRT_new_handler_func)(size_t size);
static MSVCRT_new_handler_func MSVCRT_new_handler;
static int MSVCRT_new_mode;
+/* FIXME - According to documentation it should be 8*1024, at runtime it returns 16 */
+static unsigned int MSVCRT_amblksiz = 16;
/* FIXME - According to documentation it should be 480 bytes, at runtime default is 0 */
static size_t MSVCRT_sbh_threshold = 0;
/*********************************************************************
* ??2@YAPAXI@Z (MSVCRT.@)
*/
-void* MSVCRT_operator_new(unsigned long size)
+void* CDECL MSVCRT_operator_new(size_t size)
{
- void *retval = malloc(size);
+ void *retval = HeapAlloc(GetProcessHeap(), 0, size);
TRACE("(%ld) returning %p\n", size, retval);
+ if(retval) return retval;
LOCK_HEAP;
- if(!retval && MSVCRT_new_handler)
+ if(MSVCRT_new_handler)
(*MSVCRT_new_handler)(size);
UNLOCK_HEAP;
return retval;
}
+
+/*********************************************************************
+ * ??2@YAPAXIHPBDH@Z (MSVCRT.@)
+ */
+void* CDECL MSVCRT_operator_new_dbg(size_t size, int type, const char *file, int line)
+{
+ return MSVCRT_operator_new( size );
+}
+
+
/*********************************************************************
* ??3@YAXPAX@Z (MSVCRT.@)
*/
-void MSVCRT_operator_delete(void *mem)
+void CDECL MSVCRT_operator_delete(void *mem)
{
TRACE("(%p)\n", mem);
- free(mem);
+ HeapFree(GetProcessHeap(), 0, mem);
}
/*********************************************************************
* ?_query_new_handler@@YAP6AHI@ZXZ (MSVCRT.@)
*/
-MSVCRT_new_handler_func MSVCRT__query_new_handler(void)
+MSVCRT_new_handler_func CDECL MSVCRT__query_new_handler(void)
{
return MSVCRT_new_handler;
}
@@ -78,7 +92,7 @@ MSVCRT_new_handler_func MSVCRT__query_new_handler(void)
/*********************************************************************
* ?_query_new_mode@@YAHXZ (MSVCRT.@)
*/
-int MSVCRT__query_new_mode(void)
+int CDECL MSVCRT__query_new_mode(void)
{
return MSVCRT_new_mode;
}
@@ -86,7 +100,7 @@ int MSVCRT__query_new_mode(void)
/*********************************************************************
* ?_set_new_handler@@YAP6AHI@ZP6AHI@Z@Z (MSVCRT.@)
*/
-MSVCRT_new_handler_func MSVCRT__set_new_handler(MSVCRT_new_handler_func func)
+MSVCRT_new_handler_func CDECL MSVCRT__set_new_handler(MSVCRT_new_handler_func func)
{
MSVCRT_new_handler_func old_handler;
LOCK_HEAP;
@@ -99,7 +113,7 @@ MSVCRT_new_handler_func MSVCRT__set_new_handler(MSVCRT_new_handler_func func)
/*********************************************************************
* ?set_new_handler@@YAP6AXXZP6AXXZ@Z (MSVCRT.@)
*/
-MSVCRT_new_handler_func MSVCRT_set_new_handler(void *func)
+MSVCRT_new_handler_func CDECL MSVCRT_set_new_handler(void *func)
{
TRACE("(%p)\n",func);
MSVCRT__set_new_handler(NULL);
@@ -109,7 +123,7 @@ MSVCRT_new_handler_func MSVCRT_set_new_handler(void *func)
/*********************************************************************
* ?_set_new_mode@@YAHH@Z (MSVCRT.@)
*/
-int MSVCRT__set_new_mode(int mode)
+int CDECL MSVCRT__set_new_mode(int mode)
{
int old_mode;
LOCK_HEAP;
@@ -119,45 +133,216 @@ int MSVCRT__set_new_mode(int mode)
return old_mode;
}
-int CDECL _callnewh(unsigned long size)
+/*********************************************************************
+ * _callnewh (MSVCRT.@)
+ */
+int CDECL _callnewh(size_t size)
{
- if(MSVCRT_new_handler)
- (*MSVCRT_new_handler)(size);
- return 0;
+ if(MSVCRT_new_handler)
+ (*MSVCRT_new_handler)(size);
+ return 0;
}
/*********************************************************************
- * _get_sbh_threshold (MSVCRT.@)
+ * _expand (MSVCRT.@)
*/
-size_t CDECL _get_sbh_threshold(void)
+void* CDECL _expand(void* mem, size_t size)
{
- return MSVCRT_sbh_threshold;
+ return HeapReAlloc(GetProcessHeap(), HEAP_REALLOC_IN_PLACE_ONLY, mem, size);
}
/*********************************************************************
- * _set_sbh_threshold (MSVCRT.@)
+ * _heapchk (MSVCRT.@)
*/
-int CDECL _set_sbh_threshold(size_t threshold)
+int CDECL _heapchk(void)
{
- if(threshold > 1016)
- return 0;
- else
- MSVCRT_sbh_threshold = threshold;
- return 1;
+ if (!HeapValidate( GetProcessHeap(), 0, NULL))
+ {
+ __set_errno(GetLastError());
+ return _HEAPBADNODE;
+ }
+ return _HEAPOK;
}
/*********************************************************************
- * _heapadd (MSVCRT.@)
+ * _heapmin (MSVCRT.@)
*/
-int _heapadd(void* mem, size_t size)
+int CDECL _heapmin(void)
{
- TRACE("(%p,%d) unsupported in Win32\n", mem,size);
+ if (!HeapCompact( GetProcessHeap(), 0 ))
+ {
+ if (GetLastError() != ERROR_CALL_NOT_IMPLEMENTED)
+ __set_errno(GetLastError());
+ return -1;
+ }
+ return 0;
+}
+
+/*********************************************************************
+ * _heapwalk (MSVCRT.@)
+ */
+int CDECL _heapwalk(_HEAPINFO* next)
+{
+ PROCESS_HEAP_ENTRY phe;
+
+ LOCK_HEAP;
+ phe.lpData = next->_pentry;
+ phe.cbData = next->_size;
+ phe.wFlags = next->_useflag == _USEDENTRY ? PROCESS_HEAP_ENTRY_BUSY : 0;
+
+ if (phe.lpData && phe.wFlags & PROCESS_HEAP_ENTRY_BUSY &&
+ !HeapValidate( GetProcessHeap(), 0, phe.lpData ))
+ {
+ UNLOCK_HEAP;
+ __set_errno(GetLastError());
+ return _HEAPBADNODE;
+ }
+
+ do
+ {
+ if (!HeapWalk( GetProcessHeap(), &phe ))
+ {
+ UNLOCK_HEAP;
+ if (GetLastError() == ERROR_NO_MORE_ITEMS)
+ return _HEAPEND;
+ __set_errno(GetLastError());
+ if (!phe.lpData)
+ return _HEAPBADBEGIN;
+ return _HEAPBADNODE;
+ }
+ } while (phe.wFlags & (PROCESS_HEAP_REGION|PROCESS_HEAP_UNCOMMITTED_RANGE));
+
+ UNLOCK_HEAP;
+ next->_pentry = phe.lpData;
+ next->_size = phe.cbData;
+ next->_useflag = phe.wFlags & PROCESS_HEAP_ENTRY_BUSY ? _USEDENTRY : _FREEENTRY;
+ return _HEAPOK;
+}
+
+/*********************************************************************
+ * _heapset (MSVCRT.@)
+ */
+int CDECL _heapset(unsigned int value)
+{
+ int retval;
+ _HEAPINFO heap;
+
+ memset( &heap, 0, sizeof(heap) );
+ LOCK_HEAP;
+ while ((retval = _heapwalk(&heap)) == _HEAPOK)
+ {
+ if (heap._useflag == _FREEENTRY)
+ memset(heap._pentry, value, heap._size);
+ }
+ UNLOCK_HEAP;
+ return retval == _HEAPEND? _HEAPOK : retval;
+}
+
+/*********************************************************************
+ * _heapadd (MSVCRT.@)
+ */
+int CDECL _heapadd(void* mem, size_t size)
+{
+ TRACE("(%p,%ld) unsupported in Win32\n", mem,size);
*_errno() = ENOSYS;
return -1;
}
+/*********************************************************************
+ * _heapadd (MSVCRT.@)
+ */
+intptr_t CDECL _get_heap_handle(void)
+{
+ return (intptr_t)GetProcessHeap();
+}
+
+/*********************************************************************
+ * _msize (MSVCRT.@)
+ */
+size_t CDECL _msize(void* mem)
+{
+ size_t size = HeapSize(GetProcessHeap(),0,mem);
+ if (size == ~(size_t)0)
+ {
+ WARN(":Probably called with non wine-allocated memory, ret = -1\n");
+ /* At least the Win32 crtdll/msvcrt also return -1 in this case */
+ }
+ return size;
+}
+
+/*********************************************************************
+ * calloc (MSVCRT.@)
+ */
+void* CDECL calloc(size_t size,size_t count)
+{
+ return HeapAlloc( GetProcessHeap(), HEAP_ZERO_MEMORY, size * count );
+}
+
+/*********************************************************************
+ * free (MSVCRT.@)
+ */
+void CDECL free(void* ptr)
+{
+ HeapFree(GetProcessHeap(),0,ptr);
+}
+
+/*********************************************************************
+ * malloc (MSVCRT.@)
+ */
+void* CDECL malloc(size_t size)
+{
+ void *ret = HeapAlloc(GetProcessHeap(),0,size);
+ if (!ret)
+ *_errno() = ENOMEM;
+ return ret;
+}
+
+/*********************************************************************
+ * realloc (MSVCRT.@)
+ */
+void* CDECL realloc(void* ptr, size_t size)
+{
+ if (!ptr) return malloc(size);
+ if (size) return HeapReAlloc(GetProcessHeap(), 0, ptr, size);
+ free(ptr);
+ return NULL;
+}
+
+/*********************************************************************
+ * __p__amblksiz (MSVCRT.@)
+ */
+unsigned int* CDECL __p__amblksiz(void)
+{
+ return &MSVCRT_amblksiz;
+}
+
+/*********************************************************************
+ * _get_sbh_threshold (MSVCRT.@)
+ */
+size_t CDECL _get_sbh_threshold(void)
+{
+ return MSVCRT_sbh_threshold;
+}
+
+/*********************************************************************
+ * _set_sbh_threshold (MSVCRT.@)
+ */
+int CDECL _set_sbh_threshold(size_t threshold)
+{
+ if(threshold > 1016)
+ return 0;
+ else
+ MSVCRT_sbh_threshold = threshold;
+ return 1;
+}
+
+/*********************************************************************
+ * _aligned_free (MSVCRT.@)
+ */
void CDECL _aligned_free(void *memblock)
{
+ TRACE("(%p)\n", memblock);
+
if (memblock)
{
void **saved = SAVED_PTR(memblock);
@@ -165,9 +350,13 @@ void CDECL _aligned_free(void *memblock)
}
}
+/*********************************************************************
+ * _aligned_offset_malloc (MSVCRT.@)
+ */
void * CDECL _aligned_offset_malloc(size_t size, size_t alignment, size_t offset)
{
void *memblock, *temp, **saved;
+ TRACE("(%lu, %lu, %lu)\n", size, alignment, offset);
/* alignment must be a power of 2 */
if ((alignment & (alignment - 1)) != 0)
@@ -204,16 +393,24 @@ void * CDECL _aligned_offset_malloc(size_t size, size_t alignment, size_t offset
return memblock;
}
+/*********************************************************************
+ * _aligned_malloc (MSVCRT.@)
+ */
void * CDECL _aligned_malloc(size_t size, size_t alignment)
{
+ TRACE("(%lu, %lu)\n", size, alignment);
return _aligned_offset_malloc(size, alignment, 0);
}
+/*********************************************************************
+ * _aligned_offset_realloc (MSVCRT.@)
+ */
void * CDECL _aligned_offset_realloc(void *memblock, size_t size,
size_t alignment, size_t offset)
{
void * temp, **saved;
size_t old_padding, new_padding, old_size;
+ TRACE("(%p, %lu, %lu, %lu)\n", memblock, size, alignment, offset);
if (!memblock)
return _aligned_offset_malloc(size, alignment, offset);
@@ -244,7 +441,6 @@ void * CDECL _aligned_offset_realloc(void *memblock, size_t size,
/* make sure alignment and offset didn't change */
saved = SAVED_PTR(memblock);
-
if (memblock != ALIGN_PTR(*saved, alignment, offset))
{
*_errno() = EINVAL;
@@ -255,7 +451,7 @@ void * CDECL _aligned_offset_realloc(void *memblock, size_t size,
/* Get previous size of block */
old_size = _msize(*saved);
- if (old_size == (size_t)-1)
+ if (old_size == -1)
{
/* It seems this function was called with an invalid pointer. Bail out. */
return NULL;
@@ -283,47 +479,116 @@ void * CDECL _aligned_offset_realloc(void *memblock, size_t size,
new_padding = (char *)memblock - (char *)temp;
- /*
- Memory layout of old block is as follows:
- +-------+---------------------+-+--------------------------+-----------+
- | ... | "old_padding" bytes | | ... "old_size" bytes ... | ... |
- +-------+---------------------+-+--------------------------+-----------+
- ^ ^ ^
- | | |
- *saved saved memblock
+/*
+ Memory layout of old block is as follows:
+ +-------+---------------------+-+--------------------------+-----------+
+ | ... | "old_padding" bytes | | ... "old_size" bytes ... | ... |
+ +-------+---------------------+-+--------------------------+-----------+
+ ^ ^ ^
+ | | |
+ *saved saved memblock
+ Memory layout of new block is as follows:
+ +-------+-----------------------------+-+----------------------+-------+
+ | ... | "new_padding" bytes | | ... "size" bytes ... | ... |
+ +-------+-----------------------------+-+----------------------+-------+
+ ^ ^ ^
+ | | |
+ temp saved memblock
- Memory layout of new block is as follows:
- +-------+-----------------------------+-+----------------------+-------+
- | ... | "new_padding" bytes | | ... "size" bytes ... | ... |
- +-------+-----------------------------+-+----------------------+-------+
- ^ ^ ^
- | | |
- temp saved memblock
+ However, in the new block, actual data is still written as follows
+ (because it was copied by MSVCRT_realloc):
+ +-------+---------------------+--------------------------------+-------+
+ | ... | "old_padding" bytes | ... "old_size" bytes ... | ... |
+ +-------+---------------------+--------------------------------+-------+
+ ^ ^ ^
+ | | |
+ temp saved memblock
- However, in the new block, actual data is still written as follows
- (because it was copied by MSVCRT_realloc):
- +-------+---------------------+--------------------------------+-------+
- | ... | "old_padding" bytes | ... "old_size" bytes ... | ... |
- +-------+---------------------+--------------------------------+-------+
- ^ ^ ^
- | | |
- temp saved memblock
-
- Therefore, min(old_size,size) bytes of actual data have to be moved
- from the offset they were at in the old block (temp + old_padding),
- to the offset they have to be in the new block (temp + new_padding == memblock).
- */
-
+ Therefore, min(old_size,size) bytes of actual data have to be moved
+ from the offset they were at in the old block (temp + old_padding),
+ to the offset they have to be in the new block (temp + new_padding == memblock).
+*/
if (new_padding != old_padding)
memmove((char *)memblock, (char *)temp + old_padding, (old_size < size) ? old_size : size);
*saved = temp;
return memblock;
- }
+}
+/*********************************************************************
+ * _aligned_realloc (MSVCRT.@)
+ */
void * CDECL _aligned_realloc(void *memblock, size_t size, size_t alignment)
{
+ TRACE("(%p, %lu, %lu)\n", memblock, size, alignment);
return _aligned_offset_realloc(memblock, size, alignment, 0);
}
+
+/*********************************************************************
+ * memmove_s (MSVCRT.@)
+ */
+int CDECL memmove_s(void *dest, size_t numberOfElements, const void *src, size_t count)
+{
+ TRACE("(%p %lu %p %lu)\n", dest, numberOfElements, src, count);
+
+ if(!count)
+ return 0;
+
+ if(!dest || !src) {
+ if(dest)
+ memset(dest, 0, numberOfElements);
+
+ *_errno() = EINVAL;
+ return EINVAL;
+ }
+
+ if(count > numberOfElements) {
+ memset(dest, 0, numberOfElements);
+
+ *_errno() = ERANGE;
+ return ERANGE;
+ }
+
+ memmove(dest, src, count);
+ return 0;
+}
+
+/*********************************************************************
+ * strncpy_s (MSVCRT.@)
+ */
+int CDECL strncpy_s(char *dest, size_t numberOfElements,
+ const char *src, size_t count)
+{
+ size_t i, end;
+
+ TRACE("(%s %lu %s %lu)\n", dest, numberOfElements, src, count);
+
+ if(!count)
+ return 0;
+
+ if(!dest || !src || !numberOfElements) {
+ _invalid_parameter(NULL, NULL, NULL, 0, 0);
+ *_errno() = EINVAL;
+ return EINVAL;
+ }
+
+ if(count!=_TRUNCATE && countPartitionType))
{
/* Get its offset */
Offset.QuadPart = VolumeOffset.QuadPart +
diff --git a/ntoskrnl/include/internal/amd64/ke.h b/ntoskrnl/include/internal/amd64/ke.h
index 9b5340ce6e9..7fec19af99b 100644
--- a/ntoskrnl/include/internal/amd64/ke.h
+++ b/ntoskrnl/include/internal/amd64/ke.h
@@ -314,7 +314,14 @@ KiThreadStartup(PKSYSTEM_ROUTINE SystemRoutine,
KTRAP_FRAME TrapFrame);
#endif
-#endif
+#endif /* __ASM__ */
+
+#undef KeGetCurrentThread
+#define _KeGetCurrentThread KeGetCurrentThread
+
+// HACK
+extern NTKERNELAPI volatile KSYSTEM_TIME KeTickCount;
+
#endif /* __NTOSKRNL_INCLUDE_INTERNAL_AMD64_KE_H */
/* EOF */
diff --git a/ntoskrnl/include/internal/io.h b/ntoskrnl/include/internal/io.h
index 326f19c4dc6..bec9be6d1b4 100644
--- a/ntoskrnl/include/internal/io.h
+++ b/ntoskrnl/include/internal/io.h
@@ -208,6 +208,16 @@
(_DeviceTreeTraverseContext)->Action = (_Action); \
(_DeviceTreeTraverseContext)->Context = (_Context); }
+/*
+ * BOOLEAN
+ * IopIsValidPhysicalDeviceObject(
+ * IN PDEVICE_OBJECT PhysicalDeviceObject);
+ */
+#define IopIsValidPhysicalDeviceObject(PhysicalDeviceObject) \
+ (((PEXTENDED_DEVOBJ_EXTENSION)PhysicalDeviceObject) && \
+ (((PEXTENDED_DEVOBJ_EXTENSION)PhysicalDeviceObject->DeviceObjectExtension)->DeviceNode) && \
+ (((PEXTENDED_DEVOBJ_EXTENSION)PhysicalDeviceObject->DeviceObjectExtension)->DeviceNode->Flags & DNF_ENUMERATED))
+
//
// Device List Operations
//
diff --git a/ntoskrnl/io/iomgr/deviface.c b/ntoskrnl/io/iomgr/deviface.c
index a9b5e475705..dcc086eb659 100644
--- a/ntoskrnl/io/iomgr/deviface.c
+++ b/ntoskrnl/io/iomgr/deviface.c
@@ -105,18 +105,20 @@ OpenRegistryHandlesFromSymbolicLink(IN PUNICODE_STRING SymbolicLinkName,
goto cleanup;
}
- SubKeyName.Buffer = ExAllocatePool(PagedPool, SymbolicLinkName->Length);
+ SubKeyName.MaximumLength = SymbolicLinkName->Length + sizeof(WCHAR);
+ SubKeyName.Length = 0;
+ SubKeyName.Buffer = ExAllocatePool(PagedPool, SubKeyName.MaximumLength);
if (!SubKeyName.Buffer)
{
Status = STATUS_INSUFFICIENT_RESOURCES;
goto cleanup;
}
- SubKeyName.MaximumLength = SymbolicLinkName->Length;
- SubKeyName.Length = 0;
RtlAppendUnicodeStringToString(&SubKeyName,
SymbolicLinkName);
+ SubKeyName.Buffer[SubKeyName.Length / sizeof(WCHAR)] = UNICODE_NULL;
+
SubKeyName.Buffer[0] = L'#';
SubKeyName.Buffer[1] = L'#';
SubKeyName.Buffer[2] = L'?';
diff --git a/ntoskrnl/io/pnpmgr/pnpmgr.c b/ntoskrnl/io/pnpmgr/pnpmgr.c
index 9d130eca9df..f288d263457 100644
--- a/ntoskrnl/io/pnpmgr/pnpmgr.c
+++ b/ntoskrnl/io/pnpmgr/pnpmgr.c
@@ -3507,6 +3507,10 @@ IoOpenDeviceRegistryKey(IN PDEVICE_OBJECT DeviceObject,
return STATUS_INVALID_PARAMETER;
}
+ if (!IopIsValidPhysicalDeviceObject(DeviceObject))
+ return STATUS_INVALID_DEVICE_REQUEST;
+ DeviceNode = IopGetDeviceNode(DeviceObject);
+
/*
* Calculate the length of the base key name. This is the full
* name for driver key or the name excluding "Device Parameters"
@@ -3527,7 +3531,6 @@ IoOpenDeviceRegistryKey(IN PDEVICE_OBJECT DeviceObject,
}
else
{
- DeviceNode = IopGetDeviceNode(DeviceObject);
KeyNameLength += sizeof(EnumKeyName) - sizeof(UNICODE_NULL) +
DeviceNode->InstancePath.Length;
}
diff --git a/ntoskrnl/io/pnpmgr/pnpres.c b/ntoskrnl/io/pnpmgr/pnpres.c
index 2e93929f0b0..71319f8abd1 100644
--- a/ntoskrnl/io/pnpmgr/pnpres.c
+++ b/ntoskrnl/io/pnpmgr/pnpres.c
@@ -755,7 +755,7 @@ IopTranslateDeviceResources(
DescriptorRaw->u.Interrupt.Level,
DescriptorRaw->u.Interrupt.Vector,
(PKIRQL)&DescriptorTranslated->u.Interrupt.Level,
- &DescriptorRaw->u.Interrupt.Affinity);
+ &DescriptorTranslated->u.Interrupt.Affinity);
break;
}
case CmResourceTypeMemory:
diff --git a/ntoskrnl/mm/freelist.c b/ntoskrnl/mm/freelist.c
index c3156ec79e5..5298e804d3e 100644
--- a/ntoskrnl/mm/freelist.c
+++ b/ntoskrnl/mm/freelist.c
@@ -255,7 +255,6 @@ MiAllocatePagesForMdl(IN PHYSICAL_ADDRESS LowAddress,
//
// Make sure it's really free
//
- ASSERT(MiIsPfnInUse(Pfn1) == FALSE);
ASSERT(Pfn1->u3.e2.ReferenceCount == 0);
//
diff --git a/subsystems/win32/win32k/objects/dcobjs.c b/subsystems/win32/win32k/objects/dcobjs.c
index b0ce8b5dc8f..c624836ca6d 100644
--- a/subsystems/win32/win32k/objects/dcobjs.c
+++ b/subsystems/win32/win32k/objects/dcobjs.c
@@ -299,7 +299,7 @@ NtGdiSelectBitmap(
psurfBmp->SurfObj.sizlBitmap.cx,
psurfBmp->SurfObj.sizlBitmap.cy);
- if (psurfBmp->hSecure)
+ if(psurfBmp->hSecure)
{
/* Set DIBSECTION attribute */
pdcattr->ulDirty_ |= DC_DIBSECTION;