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
819bff4d
Commit
819bff4d
authored
Jan 26, 2001
by
Andreas Mohr
Committed by
Alexandre Julliard
Jan 26, 2001
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Don't open the comm handle with GENERIC_WRITE via FILE_GetUnixHandle.
parent
06e735d2
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
11 deletions
+11
-11
comm.c
dlls/kernel/comm.c
+11
-11
No files found.
dlls/kernel/comm.c
View file @
819bff4d
...
...
@@ -1709,7 +1709,7 @@ BOOL WINAPI SetCommBreak(
#if defined(TIOCSBRK) && defined(TIOCCBRK)
/* check if available for compilation */
int
fd
,
result
;
fd
=
FILE_GetUnixHandle
(
handle
,
GENERIC_
WRITE
);
fd
=
FILE_GetUnixHandle
(
handle
,
GENERIC_
READ
);
if
(
fd
<
0
)
{
TRACE
(
"FILE_GetUnixHandle failed
\n
"
);
return
FALSE
;
...
...
@@ -1749,7 +1749,7 @@ BOOL WINAPI ClearCommBreak(
#if defined(TIOCSBRK) && defined(TIOCCBRK)
/* check if available for compilation */
int
fd
,
result
;
fd
=
FILE_GetUnixHandle
(
handle
,
GENERIC_
WRITE
);
fd
=
FILE_GetUnixHandle
(
handle
,
GENERIC_
READ
);
if
(
fd
<
0
)
{
TRACE
(
"FILE_GetUnixHandle failed
\n
"
);
return
FALSE
;
...
...
@@ -1789,7 +1789,7 @@ BOOL WINAPI EscapeCommFunction(
struct
termios
port
;
TRACE
(
"handle %d, function=%d
\n
"
,
handle
,
nFunction
);
fd
=
FILE_GetUnixHandle
(
handle
,
GENERIC_
WRITE
);
fd
=
FILE_GetUnixHandle
(
handle
,
GENERIC_
READ
);
if
(
fd
<
0
)
{
FIXME
(
"handle %d not found.
\n
"
,
handle
);
return
FALSE
;
...
...
@@ -1906,7 +1906,7 @@ BOOL WINAPI PurgeComm(
TRACE
(
"handle %d, flags %lx
\n
"
,
handle
,
flags
);
fd
=
FILE_GetUnixHandle
(
handle
,
GENERIC_
WRITE
);
fd
=
FILE_GetUnixHandle
(
handle
,
GENERIC_
READ
);
if
(
fd
<
0
)
{
FIXME
(
"no handle %d found
\n
"
,
handle
);
return
FALSE
;
...
...
@@ -2011,7 +2011,7 @@ BOOL WINAPI SetupComm(
int
fd
;
FIXME
(
"insize %ld outsize %ld unimplemented stub
\n
"
,
insize
,
outsize
);
fd
=
FILE_GetUnixHandle
(
handle
,
GENERIC_
WRITE
);
fd
=
FILE_GetUnixHandle
(
handle
,
GENERIC_
READ
);
if
(
0
>
fd
)
{
FIXME
(
"handle %d not found?
\n
"
,
handle
);
return
FALSE
;
...
...
@@ -2108,7 +2108,7 @@ BOOL WINAPI SetCommState(
TRACE
(
"%s %s
\n
"
,(
lpdcb
->
fInX
)
?
"IXON"
:
"~IXON"
,
(
lpdcb
->
fOutX
)
?
"IXOFF"
:
"~IXOFF"
);
fd
=
FILE_GetUnixHandle
(
handle
,
GENERIC_
WRITE
);
fd
=
FILE_GetUnixHandle
(
handle
,
GENERIC_
READ
);
if
(
fd
<
0
)
{
FIXME
(
"no handle %d found
\n
"
,
handle
);
return
FALSE
;
...
...
@@ -2382,7 +2382,7 @@ BOOL WINAPI SetCommState(
int
save_error
=
errno
;
commerror
=
WinError
();
close
(
fd
);
ERR
(
"tc
g
etattr error '%s'
\n
"
,
strerror
(
save_error
));
ERR
(
"tc
s
etattr error '%s'
\n
"
,
strerror
(
save_error
));
return
FALSE
;
}
else
{
commerror
=
0
;
...
...
@@ -2708,7 +2708,7 @@ BOOL WINAPI SetCommTimeouts(
if
(
!
ret
)
return
FALSE
;
/* FIXME: move this stuff to the server */
fd
=
FILE_GetUnixHandle
(
hComm
,
GENERIC_
WRITE
);
fd
=
FILE_GetUnixHandle
(
hComm
,
GENERIC_
READ
);
if
(
fd
<
0
)
{
FIXME
(
"no fd for handle = %0x!.
\n
"
,
hComm
);
return
FALSE
;
...
...
@@ -2746,14 +2746,14 @@ BOOL WINAPI GetCommModemStatus(
*
lpModemStat
=
0
;
#ifdef TIOCMGET
fd
=
FILE_GetUnixHandle
(
hFile
,
GENERIC_
WRITE
);
fd
=
FILE_GetUnixHandle
(
hFile
,
GENERIC_
READ
);
if
(
fd
<
0
)
return
FALSE
;
result
=
ioctl
(
fd
,
TIOCMGET
,
&
mstat
);
close
(
fd
);
if
(
result
==
-
1
)
{
TRACE
(
"ioctl failed
\n
"
);
WARN
(
"ioctl failed
\n
"
);
return
FALSE
;
}
#ifdef TIOCM_CTS
...
...
@@ -2773,7 +2773,7 @@ BOOL WINAPI GetCommModemStatus(
if
(
mstat
&
TIOCM_CAR
)
*
lpModemStat
|=
MS_RLSD_ON
;
#endif
TRACE
(
"%
s%s%s%s
\n
"
,
TRACE
(
"%
04x -> %s%s%s%s
\n
"
,
mstat
,
(
*
lpModemStat
&
MS_RLSD_ON
)
?
"MS_RLSD_ON "
:
""
,
(
*
lpModemStat
&
MS_RING_ON
)
?
"MS_RING_ON "
:
""
,
(
*
lpModemStat
&
MS_DSR_ON
)
?
"MS_DSR_ON "
:
""
,
...
...
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