huge docu patch
Andreas Mohr
andi at rhlx01.fht-esslingen.de
Fri Mar 29 13:14:08 CST 2002
Hi all,
and yet another one...
- update README
- more detailed error messages
- add warning to ttydrv to make sure people don't stumble and *fall*
over this problem
- add winedos load error message
- much better library load error message
- add warning to FindWindowA() that tells people how horrible the use
of this function is
- spelling fixes
--
Andreas Mohr Stauferstr. 6, D-71272 Renningen, Germany
-------------- next part --------------
Determining best CVS host...
Using CVSROOT :pserver:cvs at rhlx01.fht-esslingen.de:/home/wine
Index: README
===================================================================
RCS file: /home/wine/wine/README,v
retrieving revision 1.33
diff -u -r1.33 README
--- README 20 Mar 2002 00:59:27 -0000 1.33
+++ README 29 Mar 2002 17:10:08 -0000
@@ -108,6 +108,8 @@
Windows source code under Unix.
To see compile configuration options, do ./configure --help.
+In case of configure failure, install missing components, then
+rm config.cache, then try again.
To upgrade to a new release by using a patch file, first cd to the
top-level directory of the release (the one containing this README
@@ -143,9 +145,10 @@
See http://www.winehq.com/support.shtml for further configuration hints.
-In case of library loading errors
-(e.g. "Error while loading shared libraries: libntdll.so"), make sure
-to add the library path to /etc/ld.so.conf and run ldconfig as root.
+In case of builtin library loading errors
+(e.g. "err:module:PE_fixup_imports ERROR: DLL/library file ADVAPI32.dll(.so ?),
+which is needed by..."), make sure to add the library path to /etc/ld.so.conf
+and run ldconfig as root.
In order to verify the correctness of the environment you need for
Wine to run successfully, you may run "./tools/winecheck | less".
Index: dlls/dinput/device.c
===================================================================
RCS file: /home/wine/wine/dlls/dinput/device.c,v
retrieving revision 1.4
diff -u -r1.4 device.c
--- dlls/dinput/device.c 9 Mar 2002 23:29:36 -0000 1.4
+++ dlls/dinput/device.c 29 Mar 2002 17:10:08 -0000
@@ -184,7 +184,7 @@
dt = (DataTransform *) HeapAlloc(GetProcessHeap(), 0, asked_format->dwNumObjs * sizeof(DataTransform));
- TRACE("Creating DataTransorm : \n");
+ TRACE("Creating DataTransform : \n");
for (i = 0; i < wine_format->dwNumObjs; i++) {
offset[i] = -1;
Index: dlls/icmp/icmp_main.c
===================================================================
RCS file: /home/wine/wine/dlls/icmp/icmp_main.c,v
retrieving revision 1.19
diff -u -r1.19 icmp_main.c
--- dlls/icmp/icmp_main.c 9 Mar 2002 23:33:03 -0000 1.19
+++ dlls/icmp/icmp_main.c 29 Mar 2002 17:10:12 -0000
@@ -183,7 +183,7 @@
ISOCK_SOCKET sid=ISOCK_socket(AF_INET,SOCK_RAW,IPPROTO_ICMP);
if (!ISOCK_ISVALID(sid)) {
- MESSAGE("WARNING: Trying to use ICMP will fail unless running as root\n");
+ MESSAGE("WARNING: Trying to use ICMP (network ping) will fail unless running as root\n");
SetLastError(ERROR_ACCESS_DENIED);
return INVALID_HANDLE_VALUE;
}
Index: dlls/richedit/richedit.c
===================================================================
RCS file: /home/wine/wine/dlls/richedit/richedit.c,v
retrieving revision 1.16
diff -u -r1.16 richedit.c
--- dlls/richedit/richedit.c 9 Mar 2002 23:39:12 -0000 1.16
+++ dlls/richedit/richedit.c 29 Mar 2002 17:10:12 -0000
@@ -564,7 +564,7 @@
}
- FIXME("Unknown message %d\n", uMsg);
+ FIXME("Unknown message 0x%04x\n", uMsg);
return DefWindowProcA( hwnd,uMsg,wParam,lParam);
}
Index: dlls/ttydrv/ttydrv_main.c
===================================================================
RCS file: /home/wine/wine/dlls/ttydrv/ttydrv_main.c,v
retrieving revision 1.16
diff -u -r1.16 ttydrv_main.c
--- dlls/ttydrv/ttydrv_main.c 9 Mar 2002 23:44:30 -0000 1.16
+++ dlls/ttydrv/ttydrv_main.c 29 Mar 2002 17:10:12 -0000
@@ -80,6 +80,7 @@
{
case DLL_PROCESS_ATTACH:
process_attach();
+ MESSAGE("WARNING: ttydrv is a pretty experimental text mode driver. Most likely you want to configure wine to use x11drv instead...\n");
break;
case DLL_PROCESS_DETACH:
Index: dlls/winedos/module.c
===================================================================
RCS file: /home/wine/wine/dlls/winedos/module.c,v
retrieving revision 1.13
diff -u -r1.13 module.c
--- dlls/winedos/module.c 9 Mar 2002 23:44:32 -0000 1.13
+++ dlls/winedos/module.c 29 Mar 2002 17:10:12 -0000
@@ -279,6 +279,7 @@
TRACE("loading DOS %s image, %08lx bytes\n",old_com?"COM":"EXE",image_size);
SetFilePointer(hFile,image_start,NULL,FILE_BEGIN);
if (!ReadFile(hFile,load_start,image_size,&len,NULL) || len != image_size) {
+ ERR("File size given in header differs from actual file size - incomplete download ?\n");
SetLastError(ERROR_BAD_FORMAT);
goto load_error;
}
@@ -324,6 +325,7 @@
*/
void WINAPI MZ_LoadImage( LPCSTR filename, HANDLE hFile )
{
+ MESSAGE("Launching '%s' in DOS mode...\n", filename);
if (MZ_DoLoadImage( hFile, filename, NULL )) MZ_Launch();
}
Index: loader/module.c
===================================================================
RCS file: /home/wine/wine/loader/module.c,v
retrieving revision 1.148
diff -u -r1.148 module.c
--- loader/module.c 10 Mar 2002 00:18:34 -0000 1.148
+++ loader/module.c 29 Mar 2002 17:10:13 -0000
@@ -1127,7 +1127,7 @@
if (hFile == INVALID_HANDLE_VALUE) goto done;
if ( !MODULE_GetBinaryType( hFile, name, &type ) )
- {
+ { /* unknown file, try as unix executable */
CloseHandle( hFile );
retv = PROCESS_Create( 0, name, tidy_cmdline, lpEnvironment,
lpProcessAttributes, lpThreadAttributes,
@@ -1333,7 +1333,7 @@
{
if ( !MODULE_DllProcessAttach( wm, NULL ) )
{
- WARN_(module)("Attach failed for module '%s', \n", libname);
+ WARN_(module)("Attach failed for module '%s'.\n", libname);
MODULE_FreeLibrary(wm);
SetLastError(ERROR_DLL_INIT_FAILED);
wm = NULL;
@@ -1383,7 +1383,7 @@
* The HFILE parameter is not used and marked reserved in the SDK. I can
* only guess that it should force a file to be mapped, but I rather
* ignore the parameter because it would be extremely difficult to
- * integrate this with different types of module represenations.
+ * integrate this with different types of module representations.
*
* libdir is used to support LOAD_WITH_ALTERED_SEARCH_PATH during the recursion
* on this function. When first called from LoadLibraryExA it will be
@@ -1396,9 +1396,13 @@
* init function into load_library).
* allocated_libdir is TRUE in the stack frame that allocated libdir
*/
-WINE_MODREF *MODULE_LoadLibraryExA( LPCSTR libname, HFILE hfile, DWORD flags )
+WINE_MODREF *MODULE_LoadLibraryExA(
+ LPCSTR libname,
+ HFILE hfile,
+ DWORD flags
+)
{
- DWORD err = GetLastError();
+ DWORD err = GetLastError(), err2;
WINE_MODREF *pwm;
int i;
enum loadorder_type loadorder[LOADORDER_NTYPES];
@@ -1433,12 +1437,12 @@
if ( ! GetSystemDirectoryA ( filename, MAX_PATH ) )
goto error;
- /* if the library name contains a path and can not be found, return an error.
- exception: if the path is the system directory, proceed, so that modules,
- which are not PE-modules can be loaded
-
- if the library name does not contain a path and can not be found, assume the
- system directory is meant */
+ /* if the library name contains a path and can not be found,
+ * return an error.
+ * exception: if the path is the system directory, proceed,
+ * so that modules which are not PE modules can be loaded.
+ * If the library name does not contain a path and can not
+ * be found, assume the system directory is meant */
if ( ! FILE_strncasecmp ( filename, libname, strlen ( filename ) ))
strcpy ( filename, libname );
@@ -1449,7 +1453,7 @@
strcat ( filename, libname );
}
- /* if the filename doesn't have an extension append .DLL */
+ /* if the filename doesn't have an extension, append .DLL */
if (!(p = strrchr( filename, '.')) || strchr( p, '/' ) || strchr( p, '\\'))
strcat( filename, ".dll" );
}
@@ -1550,8 +1554,12 @@
return pwm;
}
- if(GetLastError() != ERROR_FILE_NOT_FOUND)
+ err2 = GetLastError();
+ if(err2 && err2 != ERROR_FILE_NOT_FOUND)
+ {
+ ERR("Loading of %s DLL %s failed, check this file ! (GetLastError %ld)\n", filetype, filename, err2);
break;
+ }
}
error:
@@ -1561,7 +1569,7 @@
libdir = NULL;
}
RtlLeaveCriticalSection( &loader_section );
- WARN("Failed to load module '%s'; error=0x%08lx\n", filename, GetLastError());
+ WARN("Failed to load module '%s'; error=%ld\n", filename, GetLastError());
HeapFree ( GetProcessHeap(), 0, filename );
return NULL;
}
@@ -1858,6 +1866,7 @@
if (!retproc) SetLastError(ERROR_PROC_NOT_FOUND);
}
RtlLeaveCriticalSection( &loader_section );
+ /* GPA() of e.g. W98SE does not clear the LastError in case of success */
return retproc;
}
Index: loader/pe_image.c
===================================================================
RCS file: /home/wine/wine/loader/pe_image.c,v
retrieving revision 1.107
diff -u -r1.107 pe_image.c
--- loader/pe_image.c 22 Mar 2002 00:21:23 -0000 1.107
+++ loader/pe_image.c 29 Mar 2002 17:10:14 -0000
@@ -302,7 +302,7 @@
wmImp = MODULE_LoadLibraryExA( name, 0, 0 );
if (!wmImp) {
- ERR_(module)("Module (file) %s (which is needed by %s) not found\n", name, wm->filename);
+ ERR_(module)("ERROR: DLL/library file %s(.so ?), which is needed by %s, not found or load error; fix your configuration or maybe fetch that file !\n", name, wm->filename);
return 1;
}
wm->deps[i++] = wmImp;
@@ -528,7 +528,7 @@
/**********************************************************************
* PE_CreateModule
*
- * Create WINE_MODREF structure for loaded HMODULE32, link it into
+ * Create WINE_MODREF structure for loaded HMODULE, link it into
* process modref_list, and fixup all imports.
*
* Note: hModule must point to a correctly allocated PE image,
@@ -663,7 +663,7 @@
/* FIXME: there are several more dangling references
* left. Including dlls loaded by this dll before the
* failed one. Unrolling is rather difficult with the
- * current structure and we can leave it them lying
+ * current structure and we can leave them lying
* around with no problems, so we don't care.
* As these might reference our wm, we don't free it.
*/
@@ -739,7 +739,7 @@
/* Called if the library is loaded or freed.
* NOTE: if a thread attaches a DLL, the current thread will only do
- * DLL_PROCESS_ATTACH. Only new created threads do DLL_THREAD_ATTACH
+ * DLL_PROCESS_ATTACH. Only newly created threads do DLL_THREAD_ATTACH
* (SDK)
*/
typedef DWORD (CALLBACK *DLLENTRYPROC)(HMODULE,DWORD,LPVOID);
Index: server/request.c
===================================================================
RCS file: /home/wine/wine/server/request.c,v
retrieving revision 1.61
diff -u -r1.61 request.c
--- server/request.c 10 Mar 2002 00:18:36 -0000 1.61
+++ server/request.c 29 Mar 2002 17:10:15 -0000
@@ -522,7 +522,7 @@
if (stat( ".", &st ) == -1) fatal_perror( "stat %s", serverdir );
if (!S_ISDIR(st.st_mode)) fatal_error( "%s is not a directory\n", serverdir );
if (st.st_uid != getuid()) fatal_error( "%s is not owned by you\n", serverdir );
- if (st.st_mode & 077) fatal_error( "%s must not be accessible by other users\n", serverdir );
+ if (st.st_mode & 077) fatal_error( "%s must not be accessible by other users (see \"man chmod\")\n", serverdir );
}
/* open the master server socket and start waiting for new clients */
Index: windows/win.c
===================================================================
RCS file: /home/wine/wine/windows/win.c,v
retrieving revision 1.179
diff -u -r1.179 win.c
--- windows/win.c 10 Mar 2002 00:18:37 -0000 1.179
+++ windows/win.c 29 Mar 2002 17:10:18 -0000
@@ -1587,7 +1587,10 @@
*/
HWND WINAPI FindWindowA( LPCSTR className, LPCSTR title )
{
- HWND ret = FindWindowExA( 0, 0, className, title );
+ HWND ret;
+
+ WARN("app or wine makes use of FindWindow, which is bad programming since it can hang sometimes on Windows if a window is unresponsive.\n");
+ ret = FindWindowExA( 0, 0, className, title );
if (!ret) SetLastError (ERROR_CANNOT_FIND_WND_CLASS);
return ret;
}
More information about the wine-patches
mailing list