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
4da92b60
Commit
4da92b60
authored
Jun 26, 2019
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
webservices: Build with msvcrt.
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
ba24a243
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
25 additions
and
64 deletions
+25
-64
Makefile.in
dlls/webservices/Makefile.in
+2
-0
channel.c
dlls/webservices/channel.c
+2
-7
error.c
dlls/webservices/error.c
+0
-4
heap.c
dlls/webservices/heap.c
+0
-4
listener.c
dlls/webservices/listener.c
+1
-6
msg.c
dlls/webservices/msg.c
+1
-6
proxy.c
dlls/webservices/proxy.c
+0
-4
reader.c
dlls/webservices/reader.c
+0
-4
url.c
dlls/webservices/url.c
+11
-11
writer.c
dlls/webservices/writer.c
+8
-18
No files found.
dlls/webservices/Makefile.in
View file @
4da92b60
...
...
@@ -2,6 +2,8 @@ MODULE = webservices.dll
IMPORTLIB
=
webservices
IMPORTS
=
winhttp rpcrt4 user32 ws2_32
EXTRADLLFLAGS
=
-mno-cygwin
C_SRCS
=
\
channel.c
\
error.c
\
...
...
dlls/webservices/channel.c
View file @
4da92b60
...
...
@@ -27,7 +27,6 @@
#include "wine/debug.h"
#include "wine/heap.h"
#include "wine/list.h"
#include "wine/unicode.h"
#include "webservices_private.h"
#include "sock.h"
...
...
@@ -253,11 +252,9 @@ static struct channel *alloc_channel(void)
InitializeCriticalSection
(
&
ret
->
cs
);
InitializeCriticalSection
(
&
ret
->
send_q
.
cs
);
InitializeCriticalSection
(
&
ret
->
recv_q
.
cs
);
#ifndef __MINGW32__
ret
->
cs
.
DebugInfo
->
Spare
[
0
]
=
(
DWORD_PTR
)(
__FILE__
": channel.cs"
);
ret
->
send_q
.
cs
.
DebugInfo
->
Spare
[
0
]
=
(
DWORD_PTR
)(
__FILE__
": channel.send_q.cs"
);
ret
->
recv_q
.
cs
.
DebugInfo
->
Spare
[
0
]
=
(
DWORD_PTR
)(
__FILE__
": channel.recv_q.cs"
);
#endif
prop_init
(
channel_props
,
count
,
ret
->
prop
,
&
ret
[
1
]
);
ret
->
prop_count
=
count
;
...
...
@@ -342,11 +339,9 @@ static void free_channel( struct channel *channel )
heap_free
(
channel
->
read_buf
);
#ifndef __MINGW32__
channel
->
send_q
.
cs
.
DebugInfo
->
Spare
[
0
]
=
0
;
channel
->
recv_q
.
cs
.
DebugInfo
->
Spare
[
0
]
=
0
;
channel
->
cs
.
DebugInfo
->
Spare
[
0
]
=
0
;
#endif
DeleteCriticalSection
(
&
channel
->
send_q
.
cs
);
DeleteCriticalSection
(
&
channel
->
recv_q
.
cs
);
DeleteCriticalSection
(
&
channel
->
cs
);
...
...
@@ -836,8 +831,8 @@ static HRESULT connect_channel_http( struct channel *channel )
}
else
{
strcpyW
(
channel
->
u
.
http
.
path
,
uc
.
lpszUrlPath
);
if
(
uc
.
dwExtraInfoLength
)
strcatW
(
channel
->
u
.
http
.
path
,
uc
.
lpszExtraInfo
);
l
strcpyW
(
channel
->
u
.
http
.
path
,
uc
.
lpszUrlPath
);
if
(
uc
.
dwExtraInfoLength
)
l
strcatW
(
channel
->
u
.
http
.
path
,
uc
.
lpszExtraInfo
);
}
channel
->
u
.
http
.
flags
=
WINHTTP_FLAG_REFRESH
;
...
...
dlls/webservices/error.c
View file @
4da92b60
...
...
@@ -57,9 +57,7 @@ static struct error *alloc_error(void)
ret
->
magic
=
ERROR_MAGIC
;
InitializeCriticalSection
(
&
ret
->
cs
);
#ifndef __MINGW32__
ret
->
cs
.
DebugInfo
->
Spare
[
0
]
=
(
DWORD_PTR
)(
__FILE__
": error.cs"
);
#endif
prop_init
(
error_props
,
count
,
ret
->
prop
,
&
ret
[
1
]
);
ret
->
prop_count
=
count
;
...
...
@@ -68,9 +66,7 @@ static struct error *alloc_error(void)
static
void
free_error
(
struct
error
*
error
)
{
#ifndef __MINGW32__
error
->
cs
.
DebugInfo
->
Spare
[
0
]
=
0
;
#endif
DeleteCriticalSection
(
&
error
->
cs
);
heap_free
(
error
);
}
...
...
dlls/webservices/heap.c
View file @
4da92b60
...
...
@@ -185,9 +185,7 @@ static struct heap *alloc_heap(void)
ret
->
magic
=
HEAP_MAGIC
;
InitializeCriticalSection
(
&
ret
->
cs
);
#ifndef __MINGW32__
ret
->
cs
.
DebugInfo
->
Spare
[
0
]
=
(
DWORD_PTR
)(
__FILE__
": heap.cs"
);
#endif
prop_init
(
heap_props
,
count
,
ret
->
prop
,
&
ret
[
1
]
);
ret
->
prop_count
=
count
;
...
...
@@ -247,9 +245,7 @@ void WINAPI WsFreeHeap( WS_HEAP *handle )
LeaveCriticalSection
(
&
heap
->
cs
);
#ifndef __MINGW32__
heap
->
cs
.
DebugInfo
->
Spare
[
0
]
=
0
;
#endif
DeleteCriticalSection
(
&
heap
->
cs
);
heap_free
(
heap
);
}
...
...
dlls/webservices/listener.c
View file @
4da92b60
...
...
@@ -25,7 +25,6 @@
#include "wine/debug.h"
#include "wine/heap.h"
#include "wine/list.h"
#include "wine/unicode.h"
#include "webservices_private.h"
#include "sock.h"
...
...
@@ -139,9 +138,7 @@ static struct listener *alloc_listener(void)
return
NULL
;
}
InitializeCriticalSection
(
&
ret
->
cs
);
#ifndef __MINGW32__
ret
->
cs
.
DebugInfo
->
Spare
[
0
]
=
(
DWORD_PTR
)(
__FILE__
": listener.cs"
);
#endif
prop_init
(
listener_props
,
count
,
ret
->
prop
,
&
ret
[
1
]
);
ret
->
prop_count
=
count
;
...
...
@@ -177,9 +174,7 @@ static void free_listener( struct listener *listener )
CloseHandle
(
listener
->
wait
);
CloseHandle
(
listener
->
cancel
);
#ifndef __MINGW32__
listener
->
cs
.
DebugInfo
->
Spare
[
0
]
=
0
;
#endif
DeleteCriticalSection
(
&
listener
->
cs
);
heap_free
(
listener
);
}
...
...
@@ -296,7 +291,7 @@ HRESULT resolve_hostname( const WCHAR *host, USHORT port, struct sockaddr *addr,
hints
.
ai_family
=
AF_INET
;
*
addr_len
=
0
;
s
printfW
(
service
,
fmtW
,
port
);
s
wprintf
(
service
,
ARRAY_SIZE
(
service
)
,
fmtW
,
port
);
if
(
GetAddrInfoW
(
host
,
service
,
&
hints
,
&
res
))
return
HRESULT_FROM_WIN32
(
WSAGetLastError
()
);
info
=
res
;
...
...
dlls/webservices/msg.c
View file @
4da92b60
...
...
@@ -27,7 +27,6 @@
#include "wine/debug.h"
#include "wine/heap.h"
#include "wine/list.h"
#include "wine/unicode.h"
#include "webservices_private.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
webservices
);
...
...
@@ -106,9 +105,7 @@ static struct msg *alloc_msg(void)
ret
->
header_size
=
HEADER_ARRAY_SIZE
;
InitializeCriticalSection
(
&
ret
->
cs
);
#ifndef __MINGW32__
ret
->
cs
.
DebugInfo
->
Spare
[
0
]
=
(
DWORD_PTR
)(
__FILE__
": msg.cs"
);
#endif
prop_init
(
msg_props
,
count
,
ret
->
prop
,
&
ret
[
1
]
);
ret
->
prop_count
=
count
;
...
...
@@ -164,9 +161,7 @@ static void free_msg( struct msg *msg )
WsFreeHeap
(
msg
->
heap
);
heap_free
(
msg
->
header
);
#ifndef __MINGW32__
msg
->
cs
.
DebugInfo
->
Spare
[
0
]
=
0
;
#endif
DeleteCriticalSection
(
&
msg
->
cs
);
heap_free
(
msg
);
}
...
...
@@ -1724,7 +1719,7 @@ HRESULT WINAPI WsRemoveCustomHeader( WS_MESSAGE *handle, const WS_XML_STRING *na
static
WCHAR
*
build_http_header
(
const
WCHAR
*
name
,
const
WCHAR
*
value
,
ULONG
*
ret_len
)
{
int
len_name
=
strlenW
(
name
),
len_value
=
strlenW
(
value
);
int
len_name
=
lstrlenW
(
name
),
len_value
=
l
strlenW
(
value
);
WCHAR
*
ret
=
heap_alloc
(
(
len_name
+
len_value
)
*
sizeof
(
WCHAR
)
);
if
(
!
ret
)
return
NULL
;
...
...
dlls/webservices/proxy.c
View file @
4da92b60
...
...
@@ -63,9 +63,7 @@ static struct proxy *alloc_proxy(void)
ret
->
magic
=
PROXY_MAGIC
;
InitializeCriticalSection
(
&
ret
->
cs
);
#ifndef __MINGW32__
ret
->
cs
.
DebugInfo
->
Spare
[
0
]
=
(
DWORD_PTR
)(
__FILE__
": proxy.cs"
);
#endif
prop_init
(
proxy_props
,
count
,
ret
->
prop
,
&
ret
[
1
]
);
ret
->
prop_count
=
count
;
...
...
@@ -83,9 +81,7 @@ static void free_proxy( struct proxy *proxy )
reset_proxy
(
proxy
);
WsFreeChannel
(
proxy
->
channel
);
#ifndef __MINGW32__
proxy
->
cs
.
DebugInfo
->
Spare
[
0
]
=
0
;
#endif
DeleteCriticalSection
(
&
proxy
->
cs
);
heap_free
(
proxy
);
}
...
...
dlls/webservices/reader.c
View file @
4da92b60
...
...
@@ -421,9 +421,7 @@ static struct reader *alloc_reader(void)
ret
->
magic
=
READER_MAGIC
;
InitializeCriticalSection
(
&
ret
->
cs
);
#ifndef __MINGW32__
ret
->
cs
.
DebugInfo
->
Spare
[
0
]
=
(
DWORD_PTR
)(
__FILE__
": reader.cs"
);
#endif
prop_init
(
reader_props
,
count
,
ret
->
prop
,
&
ret
[
1
]
);
ret
->
prop_count
=
count
;
...
...
@@ -520,9 +518,7 @@ static void free_reader( struct reader *reader )
heap_free
(
reader
->
prefixes
);
heap_free
(
reader
->
stream_buf
);
#ifndef __MINGW32__
reader
->
cs
.
DebugInfo
->
Spare
[
0
]
=
0
;
#endif
DeleteCriticalSection
(
&
reader
->
cs
);
heap_free
(
reader
);
}
...
...
dlls/webservices/url.c
View file @
4da92b60
...
...
@@ -20,13 +20,13 @@
#include "windef.h"
#include "winbase.h"
#include "winnls.h"
#include "winuser.h"
#include "webservices.h"
#include "wine/debug.h"
#include "wine/heap.h"
#include "wine/list.h"
#include "wine/unicode.h"
#include "webservices_private.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
webservices
);
...
...
@@ -39,19 +39,19 @@ static const WCHAR netpipe[] = {'n','e','t','.','p','i','p','e'};
static
WS_URL_SCHEME_TYPE
scheme_type
(
const
WCHAR
*
str
,
ULONG
len
)
{
if
(
len
==
ARRAY_SIZE
(
http
)
&&
!
strncmpiW
(
str
,
http
,
ARRAY_SIZE
(
http
)))
if
(
len
==
ARRAY_SIZE
(
http
)
&&
!
wcsnicmp
(
str
,
http
,
ARRAY_SIZE
(
http
)))
return
WS_URL_HTTP_SCHEME_TYPE
;
if
(
len
==
ARRAY_SIZE
(
https
)
&&
!
strncmpiW
(
str
,
https
,
ARRAY_SIZE
(
https
)))
if
(
len
==
ARRAY_SIZE
(
https
)
&&
!
wcsnicmp
(
str
,
https
,
ARRAY_SIZE
(
https
)))
return
WS_URL_HTTPS_SCHEME_TYPE
;
if
(
len
==
ARRAY_SIZE
(
nettcp
)
&&
!
strncmpiW
(
str
,
nettcp
,
ARRAY_SIZE
(
nettcp
)))
if
(
len
==
ARRAY_SIZE
(
nettcp
)
&&
!
wcsnicmp
(
str
,
nettcp
,
ARRAY_SIZE
(
nettcp
)))
return
WS_URL_NETTCP_SCHEME_TYPE
;
if
(
len
==
ARRAY_SIZE
(
soapudp
)
&&
!
strncmpiW
(
str
,
soapudp
,
ARRAY_SIZE
(
soapudp
)))
if
(
len
==
ARRAY_SIZE
(
soapudp
)
&&
!
wcsnicmp
(
str
,
soapudp
,
ARRAY_SIZE
(
soapudp
)))
return
WS_URL_SOAPUDP_SCHEME_TYPE
;
if
(
len
==
ARRAY_SIZE
(
netpipe
)
&&
!
strncmpiW
(
str
,
netpipe
,
ARRAY_SIZE
(
netpipe
)))
if
(
len
==
ARRAY_SIZE
(
netpipe
)
&&
!
wcsnicmp
(
str
,
netpipe
,
ARRAY_SIZE
(
netpipe
)))
return
WS_URL_NETPIPE_SCHEME_TYPE
;
return
~
0u
;
...
...
@@ -107,7 +107,7 @@ static WCHAR *url_decode( WCHAR *str, ULONG len, WS_HEAP *heap, ULONG *ret_len )
for
(
i
=
0
;
i
<
len
;
i
++
,
p
++
)
{
if
((
len
-
i
)
<
3
)
break
;
if
(
p
[
0
]
==
'%'
&&
is
xdigitW
(
p
[
1
]
)
&&
isxdigitW
(
p
[
2
]
))
if
(
p
[
0
]
==
'%'
&&
is
wxdigit
(
p
[
1
]
)
&&
iswxdigit
(
p
[
2
]
))
{
decode
=
TRUE
;
if
(
url_decode_byte
(
p
[
1
],
p
[
2
]
)
>
159
)
...
...
@@ -125,7 +125,7 @@ static WCHAR *url_decode( WCHAR *str, ULONG len, WS_HEAP *heap, ULONG *ret_len )
p
=
str
;
while
(
len
)
{
if
(
len
>=
3
&&
p
[
0
]
==
'%'
&&
is
xdigitW
(
p
[
1
]
)
&&
isxdigitW
(
p
[
2
]
))
if
(
len
>=
3
&&
p
[
0
]
==
'%'
&&
is
wxdigit
(
p
[
1
]
)
&&
iswxdigit
(
p
[
2
]
))
{
*
q
++
=
url_decode_byte
(
p
[
1
],
p
[
2
]
);
p
+=
3
;
...
...
@@ -214,7 +214,7 @@ HRESULT WINAPI WsDecodeUrl( const WS_STRING *str, ULONG flags, WS_HEAP *heap, WS
if
(
len
&&
*
q
==
':'
)
{
p
=
++
q
;
len
--
;
while
(
len
&&
is
digitW
(
*
q
))
while
(
len
&&
is
wdigit
(
*
q
))
{
if
((
port
=
port
*
10
+
*
q
-
'0'
)
>
65535
)
goto
done
;
q
++
;
len
--
;
...
...
@@ -481,7 +481,7 @@ HRESULT WINAPI WsEncodeUrl( const WS_URL *base, ULONG flags, WS_HEAP *heap, WS_S
{
q
=
url
->
portAsString
.
chars
;
len
=
url
->
portAsString
.
length
;
while
(
len
&&
is
digitW
(
*
q
))
while
(
len
&&
is
wdigit
(
*
q
))
{
if
((
port
=
port
*
10
+
*
q
-
'0'
)
>
65535
)
{
...
...
@@ -501,7 +501,7 @@ HRESULT WINAPI WsEncodeUrl( const WS_URL *base, ULONG flags, WS_HEAP *heap, WS_S
if
(
port
)
{
WCHAR
buf
[
7
];
len
=
s
printfW
(
buf
,
fmtW
,
port
);
len
=
s
wprintf
(
buf
,
ARRAY_SIZE
(
buf
)
,
fmtW
,
port
);
memcpy
(
p
,
buf
,
len
*
sizeof
(
WCHAR
)
);
p
+=
len
;
}
...
...
dlls/webservices/writer.c
View file @
4da92b60
...
...
@@ -16,7 +16,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
#include "config.h"
#include <assert.h>
#include <stdarg.h>
#include <stdio.h>
...
...
@@ -24,13 +23,13 @@
#include "windef.h"
#include "winbase.h"
#include "winnls.h"
#include "winuser.h"
#include "webservices.h"
#include "wine/debug.h"
#include "wine/heap.h"
#include "wine/list.h"
#include "wine/unicode.h"
#include "webservices_private.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
webservices
);
...
...
@@ -110,9 +109,7 @@ static struct writer *alloc_writer(void)
ret
->
magic
=
WRITER_MAGIC
;
InitializeCriticalSection
(
&
ret
->
cs
);
#ifndef __MINGW32__
ret
->
cs
.
DebugInfo
->
Spare
[
0
]
=
(
DWORD_PTR
)(
__FILE__
": writer.cs"
);
#endif
prop_init
(
writer_props
,
count
,
ret
->
prop
,
&
ret
[
1
]
);
ret
->
prop_count
=
count
;
...
...
@@ -126,9 +123,7 @@ static void free_writer( struct writer *writer )
WsFreeHeap
(
writer
->
output_heap
);
heap_free
(
writer
->
stream_buf
);
#ifndef __MINGW32__
writer
->
cs
.
DebugInfo
->
Spare
[
0
]
=
0
;
#endif
DeleteCriticalSection
(
&
writer
->
cs
);
heap_free
(
writer
);
}
...
...
@@ -905,10 +900,9 @@ static ULONG format_uint64( const UINT64 *ptr, unsigned char *buf )
static
ULONG
format_double
(
const
double
*
ptr
,
unsigned
char
*
buf
)
{
#ifdef HAVE_POWL
static
const
long
double
precision
=
0
.
0000000000000001
;
static
const
double
precision
=
0
.
0000000000000001
;
unsigned
char
*
p
=
buf
;
long
double
val
=
*
ptr
;
double
val
=
*
ptr
;
int
neg
,
mag
,
mag2
,
use_exp
;
if
(
isnan
(
val
))
...
...
@@ -938,12 +932,12 @@ static ULONG format_double( const double *ptr, unsigned char *buf )
val
=
-
val
;
}
mag
=
log10
l
(
val
);
mag
=
log10
(
val
);
use_exp
=
(
mag
>=
15
||
(
neg
&&
mag
>=
1
)
||
mag
<=
-
1
);
if
(
use_exp
)
{
if
(
mag
<
0
)
mag
-=
1
;
val
=
val
/
pow
l
(
10
.
0
,
mag
);
val
=
val
/
pow
(
10
.
0
,
mag
);
mag2
=
mag
;
mag
=
0
;
}
...
...
@@ -951,10 +945,10 @@ static ULONG format_double( const double *ptr, unsigned char *buf )
while
(
val
>
precision
||
mag
>=
0
)
{
long
double
weight
=
powl
(
10
.
0
,
mag
);
double
weight
=
pow
(
10
.
0
,
mag
);
if
(
weight
>
0
&&
!
isinf
(
weight
))
{
int
digit
=
floor
l
(
val
/
weight
);
int
digit
=
floor
(
val
/
weight
);
val
-=
digit
*
weight
;
*
(
p
++
)
=
'0'
+
digit
;
}
...
...
@@ -988,10 +982,6 @@ static ULONG format_double( const double *ptr, unsigned char *buf )
}
return
p
-
buf
;
#else
FIXME
(
"powl not found at build time
\n
"
);
return
0
;
#endif
}
static
inline
int
year_size
(
int
year
)
...
...
@@ -3505,7 +3495,7 @@ static HRESULT write_type_wsz( struct writer *writer, WS_TYPE_MAPPING mapping,
if
(
!
option
||
option
==
WS_WRITE_REQUIRED_VALUE
||
option
==
WS_WRITE_NILLABLE_VALUE
)
return
E_INVALIDARG
;
if
((
hr
=
get_value_ptr
(
option
,
value
,
size
,
0
,
(
const
void
**
)
&
ptr
))
!=
S_OK
)
return
hr
;
if
(
option
==
WS_WRITE_NILLABLE_POINTER
&&
!
ptr
)
return
write_add_nil_attribute
(
writer
);
if
(
!
(
len
=
strlenW
(
ptr
)))
return
S_OK
;
if
(
!
(
len
=
l
strlenW
(
ptr
)))
return
S_OK
;
utf16
.
text
.
textType
=
WS_XML_TEXT_TYPE_UTF16
;
utf16
.
bytes
=
(
BYTE
*
)
ptr
;
...
...
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