Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
c6be3fea
Commit
c6be3fea
authored
Mar 04, 2009
by
Michael Stefaniuc
Committed by
Alexandre Julliard
Mar 04, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
winedos: Remove superfluous pointer casts.
parent
f75f4e43
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
23 additions
and
28 deletions
+23
-28
dosaspi.c
dlls/winedos/dosaspi.c
+1
-1
int10.c
dlls/winedos/int10.c
+1
-1
int21.c
dlls/winedos/int21.c
+10
-13
int31.c
dlls/winedos/int31.c
+4
-6
int33.c
dlls/winedos/int33.c
+1
-1
module.c
dlls/winedos/module.c
+4
-4
relay.c
dlls/winedos/relay.c
+1
-1
xms.c
dlls/winedos/xms.c
+1
-1
No files found.
dlls/winedos/dosaspi.c
View file @
c6be3fea
...
...
@@ -196,7 +196,7 @@ static void WINAPI ASPI_DOS_func(CONTEXT86 *context)
*/
void
WINAPI
DOSVM_ASPIHandler
(
CONTEXT86
*
context
)
{
FARPROC16
*
p
=
(
FARPROC16
*
)
CTX_SEG_OFF_TO_LIN
(
context
,
context
->
SegDs
,
context
->
Edx
);
FARPROC16
*
p
=
CTX_SEG_OFF_TO_LIN
(
context
,
context
->
SegDs
,
context
->
Edx
);
TRACE
(
"DOS ASPI opening
\n
"
);
if
((
CX_reg
(
context
)
==
4
)
||
(
CX_reg
(
context
)
==
5
))
{
...
...
dlls/winedos/int10.c
View file @
c6be3fea
...
...
@@ -1249,7 +1249,7 @@ void WINAPI DOSVM_Int10Handler( CONTEXT86 *context )
BYTE
*
pt
;
TRACE
(
"Set Block of DAC registers
\n
"
);
pt
=
(
BYTE
*
)
CTX_SEG_OFF_TO_LIN
(
context
,
context
->
SegEs
,
context
->
Edx
);
pt
=
CTX_SEG_OFF_TO_LIN
(
context
,
context
->
SegEs
,
context
->
Edx
);
for
(
i
=
0
;
i
<
CX_reg
(
context
);
i
++
)
{
paldat
.
peRed
=
(
*
(
pt
+
i
*
3
+
0
))
<<
2
;
...
...
dlls/winedos/int21.c
View file @
c6be3fea
...
...
@@ -1213,8 +1213,8 @@ static BYTE *INT21_GetCurrentDTA( CONTEXT86 *context )
TDB
*
pTask
=
GlobalLock16
(
GetCurrentTask
());
/* FIXME: This assumes DTA was set correctly! */
return
(
BYTE
*
)
CTX_SEG_OFF_TO_LIN
(
context
,
SELECTOROF
(
pTask
->
dta
),
(
DWORD
)
OFFSETOF
(
pTask
->
dta
)
);
return
CTX_SEG_OFF_TO_LIN
(
context
,
SELECTOROF
(
pTask
->
dta
),
OFFSETOF
(
pTask
->
dta
)
);
}
...
...
@@ -1978,9 +1978,8 @@ static void INT21_ExtendedCountryInformation( CONTEXT86 *context )
case
0xa1
:
/* CAPITALIZE COUNTED FILENAME STRING */
TRACE
(
"Convert string to uppercase with length
\n
"
);
{
char
*
ptr
=
(
char
*
)
CTX_SEG_OFF_TO_LIN
(
context
,
context
->
SegDs
,
context
->
Edx
);
char
*
ptr
=
CTX_SEG_OFF_TO_LIN
(
context
,
context
->
SegDs
,
context
->
Edx
);
WORD
len
=
CX_reg
(
context
);
while
(
len
--
)
{
*
ptr
=
toupper
(
*
ptr
);
ptr
++
;
}
}
...
...
@@ -3117,9 +3116,8 @@ static void INT21_LongFilename( CONTEXT86 *context )
MultiByteToWideChar
(
CP_OEMCP
,
0
,
pathA
,
-
1
,
pathW
,
MAX_PATH
);
handle
=
FindFirstFileW
(
pathW
,
&
dataW
);
dataA
=
(
WIN32_FIND_DATAA
*
)
CTX_SEG_OFF_TO_LIN
(
context
,
context
->
SegEs
,
context
->
Edi
);
dataA
=
CTX_SEG_OFF_TO_LIN
(
context
,
context
->
SegEs
,
context
->
Edi
);
if
(
handle
!=
INVALID_HANDLE_VALUE
&&
(
h16
=
GlobalAlloc16
(
GMEM_MOVEABLE
,
sizeof
(
handle
))))
{
...
...
@@ -3148,8 +3146,7 @@ static void INT21_LongFilename( CONTEXT86 *context )
TRACE
(
"LONG FILENAME - FIND NEXT MATCHING FILE for handle %d
\n
"
,
BX_reg
(
context
));
dataA
=
(
WIN32_FIND_DATAA
*
)
CTX_SEG_OFF_TO_LIN
(
context
,
context
->
SegEs
,
context
->
Edi
);
dataA
=
CTX_SEG_OFF_TO_LIN
(
context
,
context
->
SegEs
,
context
->
Edi
);
if
(
h16
!=
INVALID_HANDLE_VALUE16
&&
(
ptr
=
GlobalLock16
(
h16
)))
{
...
...
@@ -3817,7 +3814,7 @@ static int INT21_FindFirst( CONTEXT86 *context )
WCHAR
maskW
[
12
],
pathW
[
MAX_PATH
];
static
const
WCHAR
wildcardW
[]
=
{
'*'
,
'.'
,
'*'
,
0
};
path
=
(
const
char
*
)
CTX_SEG_OFF_TO_LIN
(
context
,
context
->
SegDs
,
context
->
Edx
);
path
=
CTX_SEG_OFF_TO_LIN
(
context
,
context
->
SegDs
,
context
->
Edx
);
MultiByteToWideChar
(
CP_OEMCP
,
0
,
path
,
-
1
,
pathW
,
MAX_PATH
);
p
=
strrchrW
(
pathW
,
'\\'
);
...
...
@@ -3987,7 +3984,7 @@ static int INT21_FindNext( CONTEXT86 *context )
*/
static
int
INT21_FindFirstFCB
(
CONTEXT86
*
context
)
{
BYTE
*
fcb
=
(
BYTE
*
)
CTX_SEG_OFF_TO_LIN
(
context
,
context
->
SegDs
,
context
->
Edx
);
BYTE
*
fcb
=
CTX_SEG_OFF_TO_LIN
(
context
,
context
->
SegDs
,
context
->
Edx
);
FINDFILE_FCB
*
pFCB
;
int
drive
;
WCHAR
p
[]
=
{
' '
,
':'
,};
...
...
@@ -4011,7 +4008,7 @@ static int INT21_FindFirstFCB( CONTEXT86 *context )
*/
static
int
INT21_FindNextFCB
(
CONTEXT86
*
context
)
{
BYTE
*
fcb
=
(
BYTE
*
)
CTX_SEG_OFF_TO_LIN
(
context
,
context
->
SegDs
,
context
->
Edx
);
BYTE
*
fcb
=
CTX_SEG_OFF_TO_LIN
(
context
,
context
->
SegDs
,
context
->
Edx
);
FINDFILE_FCB
*
pFCB
;
LPBYTE
pResult
=
INT21_GetCurrentDTA
(
context
);
DOS_DIRENTRY_LAYOUT
*
ddl
;
...
...
dlls/winedos/int31.c
View file @
c6be3fea
...
...
@@ -1004,9 +1004,8 @@ void WINAPI DOSVM_Int31Handler( CONTEXT86 *context )
case
0x000b
:
/* Get descriptor */
TRACE
(
"get descriptor (0x%04x)
\n
"
,
BX_reg
(
context
)
);
{
LDT_ENTRY
*
entry
=
(
LDT_ENTRY
*
)
CTX_SEG_OFF_TO_LIN
(
context
,
context
->
SegEs
,
context
->
Edi
);
LDT_ENTRY
*
entry
=
CTX_SEG_OFF_TO_LIN
(
context
,
context
->
SegEs
,
context
->
Edi
);
wine_ldt_get_entry
(
BX_reg
(
context
),
entry
);
}
break
;
...
...
@@ -1014,9 +1013,8 @@ void WINAPI DOSVM_Int31Handler( CONTEXT86 *context )
case
0x000c
:
/* Set descriptor */
TRACE
(
"set descriptor (0x%04x)
\n
"
,
BX_reg
(
context
)
);
{
LDT_ENTRY
*
entry
=
(
LDT_ENTRY
*
)
CTX_SEG_OFF_TO_LIN
(
context
,
context
->
SegEs
,
context
->
Edi
);
LDT_ENTRY
*
entry
=
CTX_SEG_OFF_TO_LIN
(
context
,
context
->
SegEs
,
context
->
Edi
);
wine_ldt_set_entry
(
BX_reg
(
context
),
entry
);
}
break
;
...
...
dlls/winedos/int33.c
View file @
c6be3fea
...
...
@@ -201,7 +201,7 @@ typedef struct {
static
void
MouseRelay
(
CONTEXT86
*
context
,
void
*
mdata
)
{
MCALLDATA
*
data
=
(
MCALLDATA
*
)
mdata
;
MCALLDATA
*
data
=
mdata
;
CONTEXT86
ctx
=
*
context
;
if
(
!
ISV86
(
&
ctx
))
...
...
dlls/winedos/module.c
View file @
c6be3fea
...
...
@@ -460,7 +460,7 @@ BOOL WINAPI MZ_Exec( CONTEXT86 *context, LPCSTR filename, BYTE func, LPVOID para
WORD
fullCmdLength
;
LPBYTE
psp_start
=
(
LPBYTE
)((
DWORD
)
DOSVM_psp
<<
4
);
PDB16
*
psp
=
(
PDB16
*
)
psp_start
;
ExecBlock
*
blk
=
(
ExecBlock
*
)
paramblk
;
ExecBlock
*
blk
=
paramblk
;
LPBYTE
cmdline
=
PTR_REAL_TO_LIN
(
SELECTOROF
(
blk
->
cmdline
),
OFFSETOF
(
blk
->
cmdline
));
LPBYTE
envblock
=
PTR_REAL_TO_LIN
(
psp
->
environment
,
0
);
int
cmdLength
=
cmdline
[
0
];
...
...
@@ -530,7 +530,7 @@ BOOL WINAPI MZ_Exec( CONTEXT86 *context, LPCSTR filename, BYTE func, LPVOID para
/* MZ_LoadImage created a new PSP and loaded new values into it,
* let's work on the new values now */
LPBYTE
psp_start
=
(
LPBYTE
)((
DWORD
)
DOSVM_psp
<<
4
);
ExecBlock
*
blk
=
(
ExecBlock
*
)
paramblk
;
ExecBlock
*
blk
=
paramblk
;
LPBYTE
cmdline
=
PTR_REAL_TO_LIN
(
SELECTOROF
(
blk
->
cmdline
),
OFFSETOF
(
blk
->
cmdline
));
/* First character contains the length of the command line. */
...
...
@@ -547,7 +547,7 @@ BOOL WINAPI MZ_Exec( CONTEXT86 *context, LPCSTR filename, BYTE func, LPVOID para
*/
LPBYTE
stack
;
init_sp
-=
2
;
stack
=
(
LPBYTE
)
CTX_SEG_OFF_TO_LIN
(
context
,
init_ss
,
init_sp
);
stack
=
CTX_SEG_OFF_TO_LIN
(
context
,
init_ss
,
init_sp
);
/* FIXME: push AX correctly */
stack
[
0
]
=
0x00
;
/* push AL */
stack
[
1
]
=
0x00
;
/* push AH */
...
...
@@ -570,7 +570,7 @@ BOOL WINAPI MZ_Exec( CONTEXT86 *context, LPCSTR filename, BYTE func, LPVOID para
break
;
case
3
:
/* load overlay */
{
OverlayBlock
*
blk
=
(
OverlayBlock
*
)
paramblk
;
OverlayBlock
*
blk
=
paramblk
;
ret
=
MZ_DoLoadImage
(
hFile
,
filename
,
blk
,
0
);
}
break
;
...
...
dlls/winedos/relay.c
View file @
c6be3fea
...
...
@@ -108,7 +108,7 @@ static void __stdcall RELAY_RelayStub( DOSRELAY proc,
{
if
(
proc
)
{
CONTEXT86
*
context
=
(
CONTEXT86
*
)
ctx86
;
CONTEXT86
*
context
=
ctx86
;
RELAY_Stack16
*
stack
=
RELAY_GetPointer
(
context
->
Esp
);
DWORD
old_seg_cs
=
context
->
SegCs
;
...
...
dlls/winedos/xms.c
View file @
c6be3fea
...
...
@@ -53,7 +53,7 @@ typedef struct {
static
BYTE
*
XMS_Offset
(
MOVEOFS
*
ofs
)
{
if
(
ofs
->
Handle
)
return
(
BYTE
*
)
GlobalLock16
(
ofs
->
Handle
)
+
ofs
->
Offset
;
else
return
(
BYTE
*
)
PTR_REAL_TO_LIN
(
SELECTOROF
(
ofs
->
Offset
),
OFFSETOF
(
ofs
->
Offset
));
else
return
PTR_REAL_TO_LIN
(
SELECTOROF
(
ofs
->
Offset
),
OFFSETOF
(
ofs
->
Offset
));
}
/**********************************************************************
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment