ReactOS.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2024
December
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
October
September
August
July
June
May
April
March
February
January
2007
December
November
October
September
August
July
June
May
April
March
February
January
2006
December
November
October
September
August
July
June
May
April
March
February
January
2005
December
November
October
September
August
July
June
May
April
March
February
January
2004
December
November
October
September
August
July
June
May
April
March
February
List overview
Download
Ros-diffs
September 2013
----- 2024 -----
December 2024
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
April 2008
March 2008
February 2008
January 2008
----- 2007 -----
December 2007
November 2007
October 2007
September 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
----- 2006 -----
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
----- 2005 -----
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
----- 2004 -----
December 2004
November 2004
October 2004
September 2004
August 2004
July 2004
June 2004
May 2004
April 2004
March 2004
February 2004
ros-diffs@reactos.org
16 participants
554 discussions
Start a n
N
ew thread
[akhaldi] 60426: [WINHTTP] * Sync with Wine 1.7.1. CORE-7469
by akhaldi@svn.reactos.org
Author: akhaldi Date: Sat Sep 28 15:23:56 2013 New Revision: 60426 URL:
http://svn.reactos.org/svn/reactos?rev=60426&view=rev
Log: [WINHTTP] * Sync with Wine 1.7.1. CORE-7469 Modified: trunk/reactos/dll/win32/winhttp/CMakeLists.txt trunk/reactos/dll/win32/winhttp/main.c trunk/reactos/dll/win32/winhttp/net.c trunk/reactos/dll/win32/winhttp/request.c trunk/reactos/dll/win32/winhttp/session.c trunk/reactos/dll/win32/winhttp/winhttp_private.h trunk/reactos/media/doc/README.WINE Modified: trunk/reactos/dll/win32/winhttp/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/winhttp/CMakeLis…
============================================================================== --- trunk/reactos/dll/win32/winhttp/CMakeLists.txt [iso-8859-1] (original) +++ trunk/reactos/dll/win32/winhttp/CMakeLists.txt [iso-8859-1] Sat Sep 28 15:23:56 2013 @@ -1,11 +1,8 @@ - -add_typelib(winhttp_tlb.idl) add_definitions( -D__WINESRC__ -D_WINE) include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine) - spec2def(winhttp.dll winhttp.spec ADD_IMPORTLIB) list(APPEND SOURCE @@ -16,19 +13,14 @@ request.c session.c url.c - rsrc.rc ${CMAKE_CURRENT_BINARY_DIR}/winhttp.def) set_source_files_properties(rsrc.rc PROPERTIES OBJECT_DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/winhttp_tlb.tlb) - -add_library(winhttp SHARED ${SOURCE}) - +add_typelib(winhttp_tlb.idl) +add_library(winhttp SHARED ${SOURCE} rsrc.rc) set_module_type(winhttp win32dll) target_link_libraries(winhttp uuid wine) add_delay_importlibs(winhttp oleaut32 ole32 crypt32 secur32) add_importlibs(winhttp user32 advapi32 ws2_32 msvcrt kernel32 ntdll) - -# wininet_tlb.tlb needs stdole2.tlb -add_dependencies(winhttp stdole2) - +add_dependencies(winhttp stdole2) # wininet_tlb.tlb needs stdole2.tlb add_cd_file(TARGET winhttp DESTINATION reactos/system32 FOR all) Modified: trunk/reactos/dll/win32/winhttp/main.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/winhttp/main.c?r…
============================================================================== --- trunk/reactos/dll/win32/winhttp/main.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/winhttp/main.c [iso-8859-1] Sat Sep 28 15:23:56 2013 @@ -50,6 +50,7 @@ DisableThreadLibraryCalls(hInstDLL); break; case DLL_PROCESS_DETACH: + if (lpv) break; netconn_unload(); break; } Modified: trunk/reactos/dll/win32/winhttp/net.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/winhttp/net.c?re…
============================================================================== --- trunk/reactos/dll/win32/winhttp/net.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/winhttp/net.c [iso-8859-1] Sat Sep 28 15:23:56 2013 @@ -426,7 +426,7 @@ size = send(conn->socket, out_buf.pvBuffer, out_buf.cbBuffer, 0); if(size != out_buf.cbBuffer) { ERR("send failed\n"); - status = ERROR_WINHTTP_SECURE_CHANNEL_ERROR; + res = ERROR_WINHTTP_SECURE_CHANNEL_ERROR; break; } @@ -551,15 +551,13 @@ return TRUE; } -BOOL netconn_send( netconn_t *conn, const void *msg, size_t len, int flags, int *sent ) +BOOL netconn_send( netconn_t *conn, const void *msg, size_t len, int *sent ) { if (!netconn_connected( conn )) return FALSE; if (conn->secure) { const BYTE *ptr = msg; size_t chunk_size; - - if (flags) FIXME("flags %08x not supported in SSL\n", flags); *sent = 0; @@ -575,7 +573,7 @@ return TRUE; } - if ((*sent = send( conn->socket, msg, len, flags )) == -1) + if ((*sent = send( conn->socket, msg, len, 0 )) == -1) { set_last_error( sock_get_error( errno ) ); return FALSE; @@ -687,17 +685,7 @@ SIZE_T size, cread; BOOL res, eof; - if (flags & ~(MSG_PEEK | MSG_WAITALL)) - FIXME("SSL_read does not support the following flags: %08x\n", flags); - - if (flags & MSG_PEEK && conn->peek_msg) - { - if (len < conn->peek_len) FIXME("buffer isn't big enough, should we wrap?\n"); - *recvd = min( len, conn->peek_len ); - memcpy( buf, conn->peek_msg, *recvd ); - return TRUE; - } - else if (conn->peek_msg) + if (conn->peek_msg) { *recvd = min( len, conn->peek_len ); memcpy( buf, conn->peek_msg, *recvd ); @@ -711,7 +699,7 @@ conn->peek_msg = NULL; } /* check if we have enough data from the peek buffer */ - if (!(flags & MSG_WAITALL) || (*recvd == len)) return TRUE; + if (!(flags & MSG_WAITALL) || *recvd == len) return TRUE; } size = *recvd; @@ -732,14 +720,6 @@ size += cread; }while(!size || ((flags & MSG_WAITALL) && size < len)); - if(size && (flags & MSG_PEEK)) { - conn->peek_msg_mem = conn->peek_msg = heap_alloc(size); - if(!conn->peek_msg) - return FALSE; - - memcpy(conn->peek_msg, buf, size); - } - TRACE("received %ld bytes\n", size); *recvd = size; return TRUE; @@ -770,84 +750,6 @@ if (!(ret = ioctlsocket( conn->socket, FIONREAD, &unread ))) *available = unread; #endif return TRUE; -} - -BOOL netconn_get_next_line( netconn_t *conn, char *buffer, DWORD *buflen ) -{ - // ReactOS: use select instead of poll - fd_set infd; - BOOL ret = FALSE; - DWORD recvd = 0; - - if (!netconn_connected( conn )) return FALSE; - - if (conn->secure) - { - while (recvd < *buflen) - { - int dummy; - if (!netconn_recv( conn, &buffer[recvd], 1, 0, &dummy )) - { - set_last_error( ERROR_CONNECTION_ABORTED ); - break; - } - if (buffer[recvd] == '\n') - { - ret = TRUE; - break; - } - if (buffer[recvd] != '\r') recvd++; - } - if (ret) - { - buffer[recvd++] = 0; - *buflen = recvd; - TRACE("received line %s\n", debugstr_a(buffer)); - } - return ret; - } - - FD_ZERO(&infd); - FD_SET(conn->socket, &infd); - - while (recvd < *buflen) - { - int res; - struct timeval tv, *ptv; - socklen_t len = sizeof(tv); - - if ((res = getsockopt( conn->socket, SOL_SOCKET, SO_RCVTIMEO, (void*)&tv, &len ) != -1)) - ptv = &tv; - else - ptv = NULL; - - if (select( 0, &infd, NULL, NULL, ptv ) > 0) - { - if ((res = recv( conn->socket, &buffer[recvd], 1, 0 )) <= 0) - { - if (res == -1) set_last_error( sock_get_error( errno ) ); - break; - } - if (buffer[recvd] == '\n') - { - ret = TRUE; - break; - } - if (buffer[recvd] != '\r') recvd++; - } - else - { - set_last_error( ERROR_WINHTTP_TIMEOUT ); - break; - } - } - if (ret) - { - buffer[recvd++] = 0; - *buflen = recvd; - TRACE("received line %s\n", debugstr_a(buffer)); - } - return ret; } DWORD netconn_set_timeout( netconn_t *netconn, BOOL send, int value ) Modified: trunk/reactos/dll/win32/winhttp/request.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/winhttp/request.…
============================================================================== --- trunk/reactos/dll/win32/winhttp/request.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/winhttp/request.c [iso-8859-1] Sat Sep 28 15:23:56 2013 @@ -906,7 +906,7 @@ { int len = strlen( req_ascii ), bytes_sent; - ret = netconn_send( &request->netconn, req_ascii, len, 0, &bytes_sent ); + ret = netconn_send( &request->netconn, req_ascii, len, &bytes_sent ); heap_free( req_ascii ); if (ret) ret = read_reply( request ); @@ -950,7 +950,7 @@ struct sockaddr *saddr; DWORD len; - if (netconn_connected( &request->netconn )) return TRUE; + if (netconn_connected( &request->netconn )) goto done; connect = request->connect; port = connect->serverport ? connect->serverport : (request->hdr.flags & WINHTTP_FLAG_SECURE ? 443 : 80); @@ -1008,6 +1008,9 @@ send_callback( &request->hdr, WINHTTP_CALLBACK_STATUS_CONNECTED_TO_SERVER, addressW, strlenW(addressW) + 1 ); +done: + request->read_pos = request->read_size = 0; + request->read_chunked = FALSE; heap_free( addressW ); return TRUE; } @@ -1123,13 +1126,17 @@ send_callback( &request->hdr, WINHTTP_CALLBACK_STATUS_SENDING_REQUEST, NULL, 0 ); - ret = netconn_send( &request->netconn, req_ascii, len, 0, &bytes_sent ); + ret = netconn_send( &request->netconn, req_ascii, len, &bytes_sent ); heap_free( req_ascii ); if (!ret) goto end; - if (optional_len && !netconn_send( &request->netconn, optional, optional_len, 0, &bytes_sent )) goto end; - len += optional_len; - + if (optional_len) + { + if (!netconn_send( &request->netconn, optional, optional_len, &bytes_sent )) goto end; + request->optional = optional; + request->optional_len = optional_len; + len += optional_len; + } send_callback( &request->hdr, WINHTTP_CALLBACK_STATUS_REQUEST_SENT, &len, sizeof(DWORD) ); end: @@ -1205,29 +1212,45 @@ #define ARRAYSIZE(array) (sizeof(array) / sizeof((array)[0])) +static const WCHAR basicW[] = {'B','a','s','i','c',0}; +static const WCHAR ntlmW[] = {'N','T','L','M',0}; +static const WCHAR passportW[] = {'P','a','s','s','p','o','r','t',0}; +static const WCHAR digestW[] = {'D','i','g','e','s','t',0}; +static const WCHAR negotiateW[] = {'N','e','g','o','t','i','a','t','e',0}; + +static const struct +{ + const WCHAR *str; + unsigned int len; + DWORD scheme; +} +auth_schemes[] = +{ + { basicW, ARRAYSIZE(basicW) - 1, WINHTTP_AUTH_SCHEME_BASIC }, + { ntlmW, ARRAYSIZE(ntlmW) - 1, WINHTTP_AUTH_SCHEME_NTLM }, + { passportW, ARRAYSIZE(passportW) - 1, WINHTTP_AUTH_SCHEME_PASSPORT }, + { digestW, ARRAYSIZE(digestW) - 1, WINHTTP_AUTH_SCHEME_DIGEST }, + { negotiateW, ARRAYSIZE(negotiateW) - 1, WINHTTP_AUTH_SCHEME_NEGOTIATE } +}; +static const unsigned int num_auth_schemes = sizeof(auth_schemes)/sizeof(auth_schemes[0]); + +static enum auth_scheme scheme_from_flag( DWORD flag ) +{ + int i; + + for (i = 0; i < num_auth_schemes; i++) if (flag == auth_schemes[i].scheme) return i; + return SCHEME_INVALID; +} + static DWORD auth_scheme_from_header( WCHAR *header ) { - static const WCHAR basic[] = {'B','a','s','i','c'}; - static const WCHAR ntlm[] = {'N','T','L','M'}; - static const WCHAR passport[] = {'P','a','s','s','p','o','r','t'}; - static const WCHAR digest[] = {'D','i','g','e','s','t'}; - static const WCHAR negotiate[] = {'N','e','g','o','t','i','a','t','e'}; - - if (!strncmpiW( header, basic, ARRAYSIZE(basic) ) && - (header[ARRAYSIZE(basic)] == ' ' || !header[ARRAYSIZE(basic)])) return WINHTTP_AUTH_SCHEME_BASIC; - - if (!strncmpiW( header, ntlm, ARRAYSIZE(ntlm) ) && - (header[ARRAYSIZE(ntlm)] == ' ' || !header[ARRAYSIZE(ntlm)])) return WINHTTP_AUTH_SCHEME_NTLM; - - if (!strncmpiW( header, passport, ARRAYSIZE(passport) ) && - (header[ARRAYSIZE(passport)] == ' ' || !header[ARRAYSIZE(passport)])) return WINHTTP_AUTH_SCHEME_PASSPORT; - - if (!strncmpiW( header, digest, ARRAYSIZE(digest) ) && - (header[ARRAYSIZE(digest)] == ' ' || !header[ARRAYSIZE(digest)])) return WINHTTP_AUTH_SCHEME_DIGEST; - - if (!strncmpiW( header, negotiate, ARRAYSIZE(negotiate) ) && - (header[ARRAYSIZE(negotiate)] == ' ' || !header[ARRAYSIZE(negotiate)])) return WINHTTP_AUTH_SCHEME_NEGOTIATE; - + unsigned int i; + + for (i = 0; i < num_auth_schemes; i++) + { + if (!strncmpiW( header, auth_schemes[i].str, auth_schemes[i].len ) && + (header[auth_schemes[i].len] == ' ' || !header[auth_schemes[i].len])) return auth_schemes[i].scheme; + } return 0; } @@ -1253,10 +1276,14 @@ return FALSE; } scheme = auth_scheme_from_header( buffer ); - if (first && index == 1) *first = scheme; - *supported |= scheme; - heap_free( buffer ); + if (!scheme) break; + + if (first && index == 1) + *first = *supported = scheme; + else + *supported |= scheme; + ret = TRUE; } return ret; @@ -1283,6 +1310,13 @@ set_last_error( ERROR_WINHTTP_INCORRECT_HANDLE_TYPE ); return FALSE; } + if (!supported || !first || !target) + { + release_object( &request->hdr ); + set_last_error( ERROR_INVALID_PARAMETER ); + return FALSE; + + } if (query_auth_schemes( request, WINHTTP_QUERY_WWW_AUTHENTICATE, supported, first )) { @@ -1340,72 +1374,350 @@ return n; } -static BOOL set_credentials( request_t *request, DWORD target, DWORD scheme, LPCWSTR username, LPCWSTR password ) -{ - static const WCHAR basic[] = {'B','a','s','i','c',' ',0}; - const WCHAR *auth_scheme, *auth_target; - WCHAR *auth_header; - DWORD len, auth_data_len; - char *auth_data; +static inline char decode_char( WCHAR c ) +{ + if (c >= 'A' && c <= 'Z') return c - 'A'; + if (c >= 'a' && c <= 'z') return c - 'a' + 26; + if (c >= '0' && c <= '9') return c - '0' + 52; + if (c == '+') return 62; + if (c == '/') return 63; + return 64; +} + +static unsigned int decode_base64( const WCHAR *base64, unsigned int len, char *buf ) +{ + unsigned int i = 0; + char c0, c1, c2, c3; + const WCHAR *p = base64; + + while (len >= 4) + { + if ((c0 = decode_char( p[0] )) > 63) return 0; + if ((c1 = decode_char( p[1] )) > 63) return 0; + if ((c2 = decode_char( p[2] )) > 63) return 0; + if ((c3 = decode_char( p[3] )) > 63) return 0; + + if (buf) + { + buf[i + 0] = (c0 << 2) | (c1 >> 4); + buf[i + 1] = (c1 << 4) | (c2 >> 2); + buf[i + 2] = (c2 << 6) | c3; + } + len -= 4; + i += 3; + p += 4; + } + if (p[2] == '=') + { + if ((c0 = decode_char( p[0] )) > 63) return 0; + if ((c1 = decode_char( p[1] )) > 63) return 0; + + if (buf) buf[i] = (c0 << 2) | (c1 >> 4); + i++; + } + else if (p[3] == '=') + { + if ((c0 = decode_char( p[0] )) > 63) return 0; + if ((c1 = decode_char( p[1] )) > 63) return 0; + if ((c2 = decode_char( p[2] )) > 63) return 0; + + if (buf) + { + buf[i + 0] = (c0 << 2) | (c1 >> 4); + buf[i + 1] = (c1 << 4) | (c2 >> 2); + } + i += 2; + } + return i; +} + +static struct authinfo *alloc_authinfo(void) +{ + struct authinfo *ret; + + if (!(ret = heap_alloc( sizeof(*ret) ))) return NULL; + + SecInvalidateHandle( &ret->cred ); + SecInvalidateHandle( &ret->ctx ); + memset( &ret->exp, 0, sizeof(ret->exp) ); + ret->scheme = 0; + ret->attr = 0; + ret->max_token = 0; + ret->data = NULL; + ret->data_len = 0; + ret->finished = FALSE; + return ret; +} + +void destroy_authinfo( struct authinfo *authinfo ) +{ + if (!authinfo) return; + + if (SecIsValidHandle( &authinfo->ctx )) + DeleteSecurityContext( &authinfo->ctx ); + if (SecIsValidHandle( &authinfo->cred )) + FreeCredentialsHandle( &authinfo->cred ); + + heap_free( authinfo->data ); + heap_free( authinfo ); +} + +static BOOL get_authvalue( request_t *request, DWORD level, DWORD scheme, WCHAR *buffer, DWORD len ) +{ + DWORD size, index = 0; + for (;;) + { + size = len; + if (!query_headers( request, level, NULL, buffer, &size, &index )) return FALSE; + if (auth_scheme_from_header( buffer ) == scheme) break; + } + return TRUE; +} + +static BOOL do_authorization( request_t *request, DWORD target, DWORD scheme_flag ) +{ + struct authinfo *authinfo, **auth_ptr; + enum auth_scheme scheme = scheme_from_flag( scheme_flag ); + const WCHAR *auth_target, *username, *password; + WCHAR auth_value[2048], *auth_reply; + DWORD len = sizeof(auth_value), len_scheme, flags; BOOL ret; - if (!username || !password) - { - set_last_error( ERROR_INVALID_PARAMETER ); - return FALSE; - } + if (scheme == SCHEME_INVALID) return FALSE; switch (target) { - case WINHTTP_AUTH_TARGET_SERVER: auth_target = attr_authorization; break; - case WINHTTP_AUTH_TARGET_PROXY: auth_target = attr_proxy_authorization; break; + case WINHTTP_AUTH_TARGET_SERVER: + if (!get_authvalue( request, WINHTTP_QUERY_WWW_AUTHENTICATE, scheme_flag, auth_value, len )) + return FALSE; + auth_ptr = &request->authinfo; + auth_target = attr_authorization; + username = request->connect->username; + password = request->connect->password; + break; + + case WINHTTP_AUTH_TARGET_PROXY: + if (!get_authvalue( request, WINHTTP_QUERY_PROXY_AUTHENTICATE, scheme_flag, auth_value, len )) + return FALSE; + auth_ptr = &request->proxy_authinfo; + auth_target = attr_proxy_authorization; + username = request->connect->session->proxy_username; + password = request->connect->session->proxy_password; + break; + default: WARN("unknown target %x\n", target); return FALSE; } + authinfo = *auth_ptr; + switch (scheme) { - case WINHTTP_AUTH_SCHEME_BASIC: - { - int userlen = WideCharToMultiByte( CP_UTF8, 0, username, strlenW( username ), NULL, 0, NULL, NULL ); - int passlen = WideCharToMultiByte( CP_UTF8, 0, password, strlenW( password ), NULL, 0, NULL, NULL ); - - TRACE("basic authentication\n"); - - auth_scheme = basic; - auth_data_len = userlen + 1 + passlen; - if (!(auth_data = heap_alloc( auth_data_len ))) return FALSE; - - WideCharToMultiByte( CP_UTF8, 0, username, -1, auth_data, userlen, NULL, NULL ); - auth_data[userlen] = ':'; - WideCharToMultiByte( CP_UTF8, 0, password, -1, auth_data + userlen + 1, passlen, NULL, NULL ); + case SCHEME_BASIC: + { + int userlen, passlen; + + if (!username || !password) return FALSE; + if ((!authinfo && !(authinfo = alloc_authinfo())) || authinfo->finished) return FALSE; + + userlen = WideCharToMultiByte( CP_UTF8, 0, username, strlenW( username ), NULL, 0, NULL, NULL ); + passlen = WideCharToMultiByte( CP_UTF8, 0, password, strlenW( password ), NULL, 0, NULL, NULL ); + + authinfo->data_len = userlen + 1 + passlen; + if (!(authinfo->data = heap_alloc( authinfo->data_len ))) return FALSE; + + WideCharToMultiByte( CP_UTF8, 0, username, -1, authinfo->data, userlen, NULL, NULL ); + authinfo->data[userlen] = ':'; + WideCharToMultiByte( CP_UTF8, 0, password, -1, authinfo->data + userlen + 1, passlen, NULL, NULL ); + + authinfo->scheme = SCHEME_BASIC; + authinfo->finished = TRUE; break; } - case WINHTTP_AUTH_SCHEME_NTLM: - case WINHTTP_AUTH_SCHEME_PASSPORT: - case WINHTTP_AUTH_SCHEME_DIGEST: - case WINHTTP_AUTH_SCHEME_NEGOTIATE: - FIXME("unimplemented authentication scheme %x\n", scheme); + case SCHEME_NTLM: + case SCHEME_NEGOTIATE: + { + SECURITY_STATUS status; + SecBufferDesc out_desc, in_desc; + SecBuffer out, in; + ULONG flags = ISC_REQ_CONNECTION|ISC_REQ_USE_DCE_STYLE|ISC_REQ_MUTUAL_AUTH|ISC_REQ_DELEGATE; + const WCHAR *p; + BOOL first = FALSE; + + if (!authinfo) + { + TimeStamp exp; + SEC_WINNT_AUTH_IDENTITY_W id; + WCHAR *domain, *user; + + if (!username || !password || !(authinfo = alloc_authinfo())) return FALSE; + + first = TRUE; + domain = (WCHAR *)username; + user = strchrW( username, '\\' ); + + if (user) user++; + else + { + user = (WCHAR *)username; + domain = NULL; + } + id.Flags = SEC_WINNT_AUTH_IDENTITY_UNICODE; + id.User = user; + id.UserLength = strlenW( user ); + id.Domain = domain; + id.DomainLength = domain ? user - domain - 1 : 0; + id.Password = (WCHAR *)password; + id.PasswordLength = strlenW( password ); + + status = AcquireCredentialsHandleW( NULL, (SEC_WCHAR *)auth_schemes[scheme].str, + SECPKG_CRED_OUTBOUND, NULL, &id, NULL, NULL, + &authinfo->cred, &exp ); + if (status == SEC_E_OK) + { + PSecPkgInfoW info; + status = QuerySecurityPackageInfoW( (SEC_WCHAR *)auth_schemes[scheme].str, &info ); + if (status == SEC_E_OK) + { + authinfo->max_token = info->cbMaxToken; + FreeContextBuffer( info ); + } + } + if (status != SEC_E_OK) + { + WARN("AcquireCredentialsHandleW for scheme %s failed with error 0x%08x\n", + debugstr_w(auth_schemes[scheme].str), status); + heap_free( authinfo ); + return FALSE; + } + authinfo->scheme = scheme; + } + else if (authinfo->finished) return FALSE; + + if ((strlenW( auth_value ) < auth_schemes[authinfo->scheme].len || + strncmpiW( auth_value, auth_schemes[authinfo->scheme].str, auth_schemes[authinfo->scheme].len ))) + { + ERR("authentication scheme changed from %s to %s\n", + debugstr_w(auth_schemes[authinfo->scheme].str), debugstr_w(auth_value)); + destroy_authinfo( authinfo ); + *auth_ptr = NULL; + return FALSE; + } + in.BufferType = SECBUFFER_TOKEN; + in.cbBuffer = 0; + in.pvBuffer = NULL; + + in_desc.ulVersion = 0; + in_desc.cBuffers = 1; + in_desc.pBuffers = ∈ + + p = auth_value + auth_schemes[scheme].len; + if (*p == ' ') + { + int len = strlenW( ++p ); + in.cbBuffer = decode_base64( p, len, NULL ); + if (!(in.pvBuffer = heap_alloc( in.cbBuffer ))) return FALSE; + decode_base64( p, len, in.pvBuffer ); + } + out.BufferType = SECBUFFER_TOKEN; + out.cbBuffer = authinfo->max_token; + if (!(out.pvBuffer = heap_alloc( authinfo->max_token ))) + { + heap_free( in.pvBuffer ); + return FALSE; + } + out_desc.ulVersion = 0; + out_desc.cBuffers = 1; + out_desc.pBuffers = &out; + + status = InitializeSecurityContextW( first ? &authinfo->cred : NULL, first ? NULL : &authinfo->ctx, + first ? request->connect->servername : NULL, flags, 0, + SECURITY_NETWORK_DREP, in.pvBuffer ? &in_desc : NULL, 0, + &authinfo->ctx, &out_desc, &authinfo->attr, &authinfo->exp ); + heap_free( in.pvBuffer ); + if (status == SEC_E_OK) + { + heap_free( authinfo->data ); + authinfo->data = out.pvBuffer; + authinfo->data_len = out.cbBuffer; + authinfo->finished = TRUE; + TRACE("sending last auth packet\n"); + } + else if (status == SEC_I_CONTINUE_NEEDED) + { + heap_free( authinfo->data ); + authinfo->data = out.pvBuffer; + authinfo->data_len = out.cbBuffer; + TRACE("sending next auth packet\n"); + } + else + { + ERR("InitializeSecurityContextW failed with error 0x%08x\n", status); + heap_free( out.pvBuffer ); + destroy_authinfo( authinfo ); + *auth_ptr = NULL; + return FALSE; + } + break; + } + default: + ERR("invalid scheme %u\n", scheme); return FALSE; + } + *auth_ptr = authinfo; + + len_scheme = auth_schemes[authinfo->scheme].len; + len = len_scheme + 1 + ((authinfo->data_len + 2) * 4) / 3; + if (!(auth_reply = heap_alloc( (len + 1) * sizeof(WCHAR) ))) return FALSE; + + memcpy( auth_reply, auth_schemes[authinfo->scheme].str, len_scheme * sizeof(WCHAR) ); + auth_reply[len_scheme] = ' '; + encode_base64( authinfo->data, authinfo->data_len, auth_reply + len_scheme + 1 ); + + flags = WINHTTP_ADDREQ_FLAG_ADD | WINHTTP_ADDREQ_FLAG_REPLACE; + ret = process_header( request, auth_target, auth_reply, flags, TRUE ); + heap_free( auth_reply ); + return ret; +} + +static BOOL set_credentials( request_t *request, DWORD target, DWORD scheme, const WCHAR *username, + const WCHAR *password ) +{ + if ((scheme == WINHTTP_AUTH_SCHEME_BASIC || scheme == WINHTTP_AUTH_SCHEME_DIGEST) && + (!username || !password)) + { + set_last_error( ERROR_INVALID_PARAMETER ); + return FALSE; + } + switch (target) + { + case WINHTTP_AUTH_TARGET_SERVER: + { + heap_free( request->connect->username ); + if (!username) request->connect->username = NULL; + else if (!(request->connect->username = strdupW( username ))) return FALSE; + + heap_free( request->connect->password ); + if (!password) request->connect->password = NULL; + else if (!(request->connect->password = strdupW( password ))) return FALSE; + break; + } + case WINHTTP_AUTH_TARGET_PROXY: + { + heap_free( request->connect->session->proxy_username ); + if (!username) request->connect->session->proxy_username = NULL; + else if (!(request->connect->session->proxy_username = strdupW( username ))) return FALSE; + + heap_free( request->connect->session->proxy_password ); + if (!password) request->connect->session->proxy_password = NULL; + else if (!(request->connect->session->proxy_password = strdupW( password ))) return FALSE; + break; + } default: - WARN("unknown authentication scheme %x\n", scheme); + WARN("unknown target %u\n", target); return FALSE; } - - len = strlenW( auth_scheme ) + ((auth_data_len + 2) * 4) / 3; - if (!(auth_header = heap_alloc( (len + 1) * sizeof(WCHAR) ))) - { - heap_free( auth_data ); - return FALSE; - } - strcpyW( auth_header, auth_scheme ); - encode_base64( auth_data, auth_data_len, auth_header + strlenW( auth_header ) ); - - ret = process_header( request, auth_target, auth_header, WINHTTP_ADDREQ_FLAG_ADD | WINHTTP_ADDREQ_FLAG_REPLACE, TRUE ); - - heap_free( auth_data ); - heap_free( auth_header ); - return ret; + return TRUE; } /*********************************************************************** @@ -1439,8 +1751,7 @@ static BOOL handle_authorization( request_t *request, DWORD status ) { - DWORD schemes, level, target; - const WCHAR *username, *password; + DWORD i, schemes, first, level, target; switch (status) { @@ -1459,24 +1770,191 @@ return FALSE; } - if (!query_auth_schemes( request, level, &schemes, NULL )) return FALSE; - - if (target == WINHTTP_AUTH_TARGET_SERVER) - { - username = request->connect->username; - password = request->connect->password; - } - else - { - username = request->connect->session->proxy_username; - password = request->connect->session->proxy_password; - } - - if (schemes & WINHTTP_AUTH_SCHEME_BASIC) - return set_credentials( request, target, WINHTTP_AUTH_SCHEME_BASIC, username, password ); - - FIXME("unsupported authentication scheme\n"); + if (!query_auth_schemes( request, level, &schemes, &first )) return FALSE; + if (do_authorization( request, target, first )) return TRUE; + + schemes &= ~first; + for (i = 0; i < num_auth_schemes; i++) + { + if (!(schemes & auth_schemes[i].scheme)) continue; + if (do_authorization( request, target, auth_schemes[i].scheme )) return TRUE; + } return FALSE; +} + +/* set the request content length based on the headers */ +static DWORD set_content_length( request_t *request ) +{ + WCHAR encoding[20]; + DWORD buflen; + + buflen = sizeof(request->content_length); + if (!query_headers( request, WINHTTP_QUERY_CONTENT_LENGTH|WINHTTP_QUERY_FLAG_NUMBER, + NULL, &request->content_length, &buflen, NULL )) + request->content_length = ~0u; + + buflen = sizeof(encoding); + if (query_headers( request, WINHTTP_QUERY_TRANSFER_ENCODING, NULL, encoding, &buflen, NULL ) && + !strcmpiW( encoding, chunkedW )) + { + request->content_length = ~0u; + request->read_chunked = TRUE; + } + request->content_read = 0; + return request->content_length; +} + +/* read some more data into the read buffer */ +static BOOL read_more_data( request_t *request, int maxlen ) +{ + int len; + + if (request->read_size && request->read_pos) + { + /* move existing data to the start of the buffer */ + memmove( request->read_buf, request->read_buf + request->read_pos, request->read_size ); + request->read_pos = 0; + } + if (maxlen == -1) maxlen = sizeof(request->read_buf); + if (!netconn_recv( &request->netconn, request->read_buf + request->read_size, + maxlen - request->read_size, 0, &len )) return FALSE; + request->read_size += len; + return TRUE; +} + +/* remove some amount of data from the read buffer */ +static void remove_data( request_t *request, int count ) +{ + if (!(request->read_size -= count)) request->read_pos = 0; + else request->read_pos += count; +} + +static BOOL read_line( request_t *request, char *buffer, DWORD *len ) +{ + int count, bytes_read, pos = 0; + + for (;;) + { + char *eol = memchr( request->read_buf + request->read_pos, '\n', request->read_size ); + if (eol) + { + count = eol - (request->read_buf + request->read_pos); + bytes_read = count + 1; + } + else count = bytes_read = request->read_size; + + count = min( count, *len - pos ); + memcpy( buffer + pos, request->read_buf + request->read_pos, count ); + pos += count; + remove_data( request, bytes_read ); + if (eol) break; + + if (!read_more_data( request, -1 )) return FALSE; + if (!request->read_size) + { + *len = 0; + TRACE("returning empty string\n"); + return FALSE; + } + } + if (pos < *len) + { + if (pos && buffer[pos - 1] == '\r') pos--; + *len = pos + 1; + } + buffer[*len - 1] = 0; + TRACE("returning %s\n", debugstr_a(buffer)); + return TRUE; +} + +/* discard data contents until we reach end of line */ +static BOOL discard_eol( request_t *request ) +{ + do + { + char *eol = memchr( request->read_buf + request->read_pos, '\n', request->read_size ); + if (eol) + { + remove_data( request, (eol + 1) - (request->read_buf + request->read_pos) ); + break; + } + request->read_pos = request->read_size = 0; /* discard everything */ + if (!read_more_data( request, -1 )) return FALSE; + } while (request->read_size); + return TRUE; +} + +/* read the size of the next chunk */ +static BOOL start_next_chunk( request_t *request ) +{ + DWORD chunk_size = 0; + + if (!request->content_length) return TRUE; + if (request->content_length == request->content_read) + { + /* read terminator for the previous chunk */ + if (!discard_eol( request )) return FALSE; + request->content_length = ~0u; + request->content_read = 0; + } + for (;;) + { + while (request->read_size) + { + char ch = request->read_buf[request->read_pos]; + if (ch >= '0' && ch <= '9') chunk_size = chunk_size * 16 + ch - '0'; + else if (ch >= 'a' && ch <= 'f') chunk_size = chunk_size * 16 + ch - 'a' + 10; + else if (ch >= 'A' && ch <= 'F') chunk_size = chunk_size * 16 + ch - 'A' + 10; + else if (ch == ';' || ch == '\r' || ch == '\n') + { + TRACE("reading %u byte chunk\n", chunk_size); + request->content_length = chunk_size; + request->content_read = 0; + if (!discard_eol( request )) return FALSE; + return TRUE; + } + remove_data( request, 1 ); + } + if (!read_more_data( request, -1 )) return FALSE; + if (!request->read_size) + { + request->content_length = request->content_read = 0; + return TRUE; + } + } +} + +/* return the size of data available to be read immediately */ +static DWORD get_available_data( request_t *request ) +{ + if (request->read_chunked && + (request->content_length == ~0u || request->content_length == request->content_read)) + return 0; + return min( request->read_size, request->content_length - request->content_read ); +} + +/* check if we have reached the end of the data to read */ +static BOOL end_of_read_data( request_t *request ) +{ + if (request->read_chunked) return (request->content_length == 0); + if (request->content_length == ~0u) return FALSE; + return (request->content_length == request->content_read); +} + +static BOOL refill_buffer( request_t *request ) +{ + int len = sizeof(request->read_buf); + + if (request->read_chunked && + (request->content_length == ~0u || request->content_length == request->content_read)) + { + if (!start_next_chunk( request )) return FALSE; + } + if (request->content_length != ~0u) len = min( len, request->content_length - request->content_read ); + if (len <= request->read_size) return TRUE; + if (!read_more_data( request, len )) return FALSE; + if (!request->read_size) request->content_length = request->content_read = 0; + return TRUE; } #define MAX_REPLY_LEN 1460 @@ -1500,7 +1978,7 @@ do { buflen = MAX_REPLY_LEN; - if (!netconn_get_next_line( &request->netconn, buffer, &buflen )) return FALSE; + if (!read_line( request, buffer, &buflen )) return FALSE; received_len += buflen; /* first line should look like 'HTTP/1.x nnn OK' where nnn is the status code */ @@ -1551,7 +2029,7 @@ header_t *header; buflen = MAX_REPLY_LEN; - if (!netconn_get_next_line( &request->netconn, buffer, &buflen )) goto end; + if (!read_line( request, buffer, &buflen )) goto end; received_len += buflen; if (!*buffer) break; @@ -1582,101 +2060,6 @@ return TRUE; } -static BOOL receive_data( request_t *request, void *buffer, DWORD size, DWORD *read, BOOL async ) -{ - DWORD to_read; - int bytes_read; - - to_read = min( size, request->content_length - request->content_read ); - if (!netconn_recv( &request->netconn, buffer, to_read, async ? 0 : MSG_WAITALL, &bytes_read )) - { - if (bytes_read != to_read) - { - ERR("not all data received %d/%d\n", bytes_read, to_read); - } - /* always return success, even if the network layer returns an error */ - *read = 0; - return TRUE; - } - request->content_read += bytes_read; - *read = bytes_read; - return TRUE; -} - -static DWORD get_chunk_size( const char *buffer ) -{ - const char *p; - DWORD size = 0; - - for (p = buffer; *p; p++) - { - if (*p >= '0' && *p <= '9') size = size * 16 + *p - '0'; - else if (*p >= 'a' && *p <= 'f') size = size * 16 + *p - 'a' + 10; - else if (*p >= 'A' && *p <= 'F') size = size * 16 + *p - 'A' + 10; - else if (*p == ';') break; - } - return size; -} - -static BOOL receive_data_chunked( request_t *request, void *buffer, DWORD size, DWORD *read, BOOL async ) -{ - char reply[MAX_REPLY_LEN], *p = buffer; - DWORD buflen, to_read, to_write = size; - int bytes_read; - - *read = 0; - for (;;) - { - if (*read == size) break; - - if (request->content_length == ~0u) /* new chunk */ - { - buflen = sizeof(reply); - if (!netconn_get_next_line( &request->netconn, reply, &buflen )) break; - - if (!(request->content_length = get_chunk_size( reply ))) - { - /* zero sized chunk marks end of transfer; read any trailing headers and return */ - read_reply( request ); - break; - } - } - to_read = min( to_write, request->content_length - request->content_read ); - - if (!netconn_recv( &request->netconn, p, to_read, async ? 0 : MSG_WAITALL, &bytes_read )) - { - if (bytes_read != to_read) - { - ERR("Not all data received %d/%d\n", bytes_read, to_read); - } - /* always return success, even if the network layer returns an error */ - *read = 0; - break; - } - if (!bytes_read) break; - - request->content_read += bytes_read; - to_write -= bytes_read; - *read += bytes_read; - p += bytes_read; - - if (request->content_read == request->content_length) /* chunk complete */ - { - request->content_read = 0; - request->content_length = ~0u; - - buflen = sizeof(reply); - if (!netconn_get_next_line( &request->netconn, reply, &buflen )) - { - ERR("Malformed chunk\n"); - *read = 0; - break; - } - } - } - return TRUE; -} - static void finished_reading( request_t *request ) { static const WCHAR closeW[] = {'c','l','o','s','e',0}; @@ -1692,31 +2075,40 @@ if (!strcmpiW( connection, closeW )) close = TRUE; } else if (!strcmpW( request->version, http1_0 )) close = TRUE; - if (close) close_connection( request ); - request->content_length = ~0u; - request->content_read = 0; -} - -static BOOL read_data( request_t *request, void *buffer, DWORD to_read, DWORD *read, BOOL async ) -{ - static const WCHAR chunked[] = {'c','h','u','n','k','e','d',0}; - - BOOL ret; - WCHAR encoding[20]; - DWORD num_bytes, buflen = sizeof(encoding); - - if (query_headers( request, WINHTTP_QUERY_TRANSFER_ENCODING, NULL, encoding, &buflen, NULL ) && - !strcmpiW( encoding, chunked )) - { - ret = receive_data_chunked( request, buffer, to_read, &num_bytes, async ); - } - else - ret = receive_data( request, buffer, to_read, &num_bytes, async ); - +} + +static BOOL read_data( request_t *request, void *buffer, DWORD size, DWORD *read, BOOL async ) +{ + BOOL ret = TRUE; + int len, bytes_read = 0; + + if (request->read_chunked && + (request->content_length == ~0u || request->content_length == request->content_read)) + { + if (!start_next_chunk( request )) goto done; + } + if (request->content_length != ~0u) size = min( size, request->content_length - request->content_read ); + + if (request->read_size) + { + bytes_read = min( request->read_size, size ); + memcpy( buffer, request->read_buf + request->read_pos, bytes_read ); + remove_data( request, bytes_read ); + } + if (size > bytes_read && (!bytes_read || !async)) + { + if ((ret = netconn_recv( &request->netconn, (char *)buffer + bytes_read, size - bytes_read, + async ? 0 : MSG_WAITALL, &len ))) + bytes_read += len; + } + +done: + request->content_read += bytes_read; + TRACE( "retrieved %u bytes (%u/%u)\n", bytes_read, request->content_read, request->content_length ); if (async) { - if (ret) send_callback( &request->hdr, WINHTTP_CALLBACK_STATUS_READ_COMPLETE, buffer, num_bytes ); + if (ret) send_callback( &request->hdr, WINHTTP_CALLBACK_STATUS_READ_COMPLETE, buffer, bytes_read ); else { WINHTTP_ASYNC_RESULT result; @@ -1725,11 +2117,8 @@ send_callback( &request->hdr, WINHTTP_CALLBACK_STATUS_REQUEST_ERROR, &result, sizeof(result) ); } } - if (ret) - { - if (read) *read = num_bytes; - if (!num_bytes) finished_reading( request ); - } + if (read) *read = bytes_read; + if (!bytes_read && request->content_read == request->content_length) finished_reading( request ); return ret; } @@ -1739,7 +2128,7 @@ DWORD bytes_read; char buffer[2048]; - if (!request->content_length) + if (request->content_length == ~0u) { finished_reading( request ); return; @@ -1843,6 +2232,8 @@ netconn_close( &request->netconn ); if (!(ret = netconn_init( &request->netconn ))) goto end; + request->read_pos = request->read_size = 0; + request->read_chunked = FALSE; } if (!(ret = add_host_header( request, WINHTTP_ADDREQ_FLAG_REPLACE ))) goto end; if (!(ret = open_connection( request ))) goto end; @@ -1866,6 +2257,8 @@ { heap_free( request->verb ); request->verb = strdupW( getW ); + request->optional = NULL; + request->optional_len = 0; } ret = TRUE; @@ -1891,10 +2284,7 @@ query = WINHTTP_QUERY_STATUS_CODE | WINHTTP_QUERY_FLAG_NUMBER; if (!(ret = query_headers( request, query, NULL, &status, &size, NULL ))) break; - size = sizeof(DWORD); - query = WINHTTP_QUERY_CONTENT_LENGTH | WINHTTP_QUERY_FLAG_NUMBER; - if (!query_headers( request, query, NULL, &request->content_length, &size, NULL )) - request->content_length = ~0u; + set_content_length( request ); if (!(request->hdr.disable_flags & WINHTTP_DISABLE_COOKIES)) record_cookies( request ); @@ -1905,7 +2295,8 @@ if (!(ret = handle_redirect( request, status ))) break; - send_request( request, NULL, 0, NULL, 0, 0, 0, FALSE ); /* recurse synchronously */ + /* recurse synchronously */ + send_request( request, NULL, 0, request->optional, request->optional_len, 0, 0, FALSE ); continue; } else if (status == HTTP_STATUS_DENIED || status == HTTP_STATUS_PROXY_AUTH_REQ) @@ -1918,7 +2309,8 @@ ret = TRUE; break; } - send_request( request, NULL, 0, NULL, 0, 0, 0, FALSE ); + /* recurse synchronously */ + send_request( request, NULL, 0, request->optional, request->optional_len, 0, 0, FALSE ); continue; } break; @@ -1984,35 +2376,33 @@ return ret; } -static BOOL query_data( request_t *request, LPDWORD available, BOOL async ) -{ - BOOL ret; - DWORD num_bytes; - - if ((ret = netconn_query_data_available( &request->netconn, &num_bytes ))) - { - if (request->content_read < request->content_length) - { - if (!num_bytes) - { - char buffer[4096]; - size_t to_read = min( sizeof(buffer), request->content_length - request->content_read ); - - ret = netconn_recv( &request->netconn, buffer, to_read, MSG_PEEK, (int *)&num_bytes ); - if (ret && !num_bytes) WARN("expected more data to be available\n"); - } - } - else if (num_bytes) - { - WARN("extra data available %u\n", num_bytes); - ret = FALSE; - } - } - TRACE("%u bytes available\n", num_bytes); - +static BOOL query_data_available( request_t *request, DWORD *available, BOOL async ) +{ + BOOL ret = TRUE; + DWORD count; + + if (!(count = get_available_data( request ))) + { + if (end_of_read_data( request )) + { + if (available) *available = 0; + return TRUE; + } + } + refill_buffer( request ); + count = get_available_data( request ); + + if (count == sizeof(request->read_buf)) /* check if we have even more pending in the socket */ + { + DWORD extra; + if ((ret = netconn_query_data_available( &request->netconn, &extra ))) + { + count = min( count + extra, request->content_length - request->content_read ); + } + } if (async) { - if (ret) send_callback( &request->hdr, WINHTTP_CALLBACK_STATUS_DATA_AVAILABLE, &num_bytes, sizeof(DWORD) ); + if (ret) send_callback( &request->hdr, WINHTTP_CALLBACK_STATUS_DATA_AVAILABLE, &count, sizeof(count) ); else { WINHTTP_ASYNC_RESULT result; @@ -2021,14 +2411,18 @@ send_callback( &request->hdr, WINHTTP_CALLBACK_STATUS_REQUEST_ERROR, &result, sizeof(result) ); } } - if (ret && available) *available = num_bytes; + if (ret) + { + TRACE("%u bytes available\n", count); + if (available) *available = count; + } return ret; } -static void task_query_data( task_header_t *task ) +static void task_query_data_available( task_header_t *task ) { query_data_t *q = (query_data_t *)task; - query_data( q->hdr.request, q->available, TRUE ); + query_data_available( q->hdr.request, q->available, TRUE ); } /*********************************************************************** @@ -2059,14 +2453,14 @@ if (!(q = heap_alloc( sizeof(query_data_t) ))) return FALSE; q->hdr.request = request; - q->hdr.proc = task_query_data; + q->hdr.proc = task_query_data_available; q->available = available; addref_object( &request->hdr ); ret = queue_task( (task_header_t *)q ); } else - ret = query_data( request, available, FALSE ); + ret = query_data_available( request, available, FALSE ); release_object( &request->hdr ); return ret; @@ -2126,7 +2520,7 @@ BOOL ret; int num_bytes; - ret = netconn_send( &request->netconn, buffer, to_write, 0, &num_bytes ); + ret = netconn_send( &request->netconn, buffer, to_write, &num_bytes ); if (async) { Modified: trunk/reactos/dll/win32/winhttp/session.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/winhttp/session.…
============================================================================== --- trunk/reactos/dll/win32/winhttp/session.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/winhttp/session.c [iso-8859-1] Sat Sep 28 15:23:56 2013 @@ -559,6 +559,9 @@ TRACE("%p\n", request); release_object( &request->connect->hdr ); + + destroy_authinfo( request->authinfo ); + destroy_authinfo( request->proxy_authinfo ); heap_free( request->verb ); heap_free( request->path ); Modified: trunk/reactos/dll/win32/winhttp/winhttp_private.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/winhttp/winhttp_…
============================================================================== --- trunk/reactos/dll/win32/winhttp/winhttp_private.h [iso-8859-1] (original) +++ trunk/reactos/dll/win32/winhttp/winhttp_private.h [iso-8859-1] Sat Sep 28 15:23:56 2013 @@ -51,6 +51,7 @@ static const WCHAR slashW[] = {'/',0}; static const WCHAR http1_0[] = {'H','T','T','P','/','1','.','0',0}; static const WCHAR http1_1[] = {'H','T','T','P','/','1','.','1',0}; +static const WCHAR chunkedW[] = {'c','h','u','n','k','e','d',0}; typedef struct _object_header_t object_header_t; @@ -146,6 +147,29 @@ BOOL is_request; /* part of request headers? */ } header_t; +enum auth_scheme +{ + SCHEME_INVALID = -1, + SCHEME_BASIC, + SCHEME_NTLM, + SCHEME_PASSPORT, + SCHEME_DIGEST, + SCHEME_NEGOTIATE +}; + +struct authinfo +{ + enum auth_scheme scheme; + CredHandle cred; + CtxtHandle ctx; + TimeStamp exp; + ULONG attr; + ULONG max_token; + char *data; + unsigned int data_len; + BOOL finished; /* finished authenticating */ +}; + typedef struct { object_header_t hdr; @@ -154,6 +178,8 @@ LPWSTR path; LPWSTR version; LPWSTR raw_headers; + void *optional; + DWORD optional_len; netconn_t netconn; int resolve_timeout; int connect_timeout; @@ -162,10 +188,16 @@ LPWSTR status_text; DWORD content_length; /* total number of bytes to be read (per chunk) */ DWORD content_read; /* bytes read so far */ + BOOL read_chunked; /* are we reading in chunked mode? */ + DWORD read_pos; /* current read position in read_buf */ + DWORD read_size; /* valid data size in read_buf */ + char read_buf[4096]; /* buffer for already read but not returned data */ header_t *headers; DWORD num_headers; WCHAR **accept_types; DWORD num_accept_types; + struct authinfo *authinfo; + struct authinfo *proxy_authinfo; } request_t; typedef struct _task_header_t task_header_t; @@ -229,14 +261,13 @@ BOOL netconn_connect( netconn_t *, const struct sockaddr *, unsigned int, int ) DECLSPEC_HIDDEN; BOOL netconn_connected( netconn_t * ) DECLSPEC_HIDDEN; BOOL netconn_create( netconn_t *, int, int, int ) DECLSPEC_HIDDEN; -BOOL netconn_get_next_line( netconn_t *, char *, DWORD * ) DECLSPEC_HIDDEN; BOOL netconn_init( netconn_t * ) DECLSPEC_HIDDEN; void netconn_unload( void ) DECLSPEC_HIDDEN; BOOL netconn_query_data_available( netconn_t *, DWORD * ) DECLSPEC_HIDDEN; BOOL netconn_recv( netconn_t *, void *, size_t, int, int * ) DECLSPEC_HIDDEN; BOOL netconn_resolve( WCHAR *, INTERNET_PORT, struct sockaddr *, socklen_t *, int ) DECLSPEC_HIDDEN; BOOL netconn_secure_connect( netconn_t *, WCHAR * ) DECLSPEC_HIDDEN; -BOOL netconn_send( netconn_t *, const void *, size_t, int, int * ) DECLSPEC_HIDDEN; +BOOL netconn_send( netconn_t *, const void *, size_t, int * ) DECLSPEC_HIDDEN; DWORD netconn_set_timeout( netconn_t *, BOOL, int ) DECLSPEC_HIDDEN; const void *netconn_get_certificate( netconn_t * ) DECLSPEC_HIDDEN; int netconn_get_cipher_strength( netconn_t * ) DECLSPEC_HIDDEN; @@ -245,7 +276,8 @@ BOOL add_cookie_headers( request_t * ) DECLSPEC_HIDDEN; BOOL add_request_headers( request_t *, LPCWSTR, DWORD, DWORD ) DECLSPEC_HIDDEN; void delete_domain( domain_t * ) DECLSPEC_HIDDEN; -BOOL set_server_for_hostname( connect_t *connect, LPCWSTR server, INTERNET_PORT port ) DECLSPEC_HIDDEN; +BOOL set_server_for_hostname( connect_t *, LPCWSTR, INTERNET_PORT ) DECLSPEC_HIDDEN; +void destroy_authinfo( struct authinfo * ) DECLSPEC_HIDDEN; extern HRESULT WinHttpRequest_create( IUnknown *, void ** ) DECLSPEC_HIDDEN; Modified: trunk/reactos/media/doc/README.WINE URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/media/doc/README.WINE?rev=…
============================================================================== --- trunk/reactos/media/doc/README.WINE [iso-8859-1] (original) +++ trunk/reactos/media/doc/README.WINE [iso-8859-1] Sat Sep 28 15:23:56 2013 @@ -202,7 +202,7 @@ reactos/dll/win32/windowscodecs # Synced to Wine-1.7.1 reactos/dll/win32/winemp3.acm # Synced to Wine-1.7.1 reactos/dll/win32/wing32 # Out of sync -reactos/dll/win32/winhttp # Synced to Wine-1.5.26 +reactos/dll/win32/winhttp # Synced to Wine-1.7.1 reactos/dll/win32/wininet # Synced to Wine-1.5.26 reactos/dll/win32/winmm # Forked at Wine-20050628 reactos/dll/win32/winmm/midimap # Forked at Wine-20050628
11 years, 2 months
1
0
0
0
[akhaldi] 60425: * Forgot wbemcli.idl.
by akhaldi@svn.reactos.org
Author: akhaldi Date: Sat Sep 28 15:21:53 2013 New Revision: 60425 URL:
http://svn.reactos.org/svn/reactos?rev=60425&view=rev
Log: * Forgot wbemcli.idl. Modified: trunk/reactos/include/psdk/wbemcli.idl Modified: trunk/reactos/include/psdk/wbemcli.idl URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/psdk/wbemcli.idl?r…
============================================================================== --- trunk/reactos/include/psdk/wbemcli.idl [iso-8859-1] (original) +++ trunk/reactos/include/psdk/wbemcli.idl [iso-8859-1] Sat Sep 28 15:21:53 2013 @@ -176,6 +176,13 @@ WBEM_E_PROVIDER_DISABLED = 0x8004108a } WBEMSTATUS; +typedef [v1_enum] enum tag_WBEM_STATUS_TYPE +{ + WBEM_STATUS_COMPLETE = 0, + WBEM_STATUS_REQUIREMENTS = 1, + WBEM_STATUS_PROGRESS = 2 +} WBEM_STATUS_TYPE; + typedef [v1_enum] enum tag_WBEM_TIMEOUT_TYPE { WBEM_NO_WAIT = 0, @@ -290,6 +297,24 @@ [out] BSTR *MessageText); }; +[ + object, + restricted, + uuid(7c857801-7381-11cf-884d-00aa004b2e24) +] +interface IWbemObjectSink : IUnknown +{ + HRESULT Indicate( + [in] long lObjectCount, + [in, size_is(lObjectCount)] IWbemClassObject **apObjArray); + + HRESULT SetStatus( + [in] long lFlags, + [in] HRESULT hResult, + [in] BSTR strParam, + [in] IWbemClassObject *pObjParam); +}; + typedef [v1_enum] enum tag_WBEM_GENERIC_FLAG_TYPE { WBEM_FLAG_RETURN_WBEM_COMPLETE = 0,
11 years, 2 months
1
0
0
0
[akhaldi] 60424: [WINEMP3.ACM] * Sync with Wine 1.7.1. CORE-7469
by akhaldi@svn.reactos.org
Author: akhaldi Date: Sat Sep 28 15:20:19 2013 New Revision: 60424 URL:
http://svn.reactos.org/svn/reactos?rev=60424&view=rev
Log: [WINEMP3.ACM] * Sync with Wine 1.7.1. CORE-7469 Modified: trunk/reactos/dll/win32/winemp3.acm/CMakeLists.txt trunk/reactos/dll/win32/winemp3.acm/mpegl3.c trunk/reactos/media/doc/README.WINE Modified: trunk/reactos/dll/win32/winemp3.acm/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/winemp3.acm/CMak…
============================================================================== --- trunk/reactos/dll/win32/winemp3.acm/CMakeLists.txt [iso-8859-1] (original) +++ trunk/reactos/dll/win32/winemp3.acm/CMakeLists.txt [iso-8859-1] Sat Sep 28 15:20:19 2013 @@ -16,13 +16,5 @@ set_module_type(winemp3.acm win32dll) set_target_properties(winemp3.acm PROPERTIES SUFFIX "") target_link_libraries(winemp3.acm wine libmpg123 oldnames) - -add_importlibs(winemp3.acm - winmm - user32 - msvcrt - kernel32 - ntdll) - -add_dependencies(winemp3.acm psdk) +add_importlibs(winemp3.acm winmm user32 msvcrt kernel32 ntdll) add_cd_file(TARGET winemp3.acm DESTINATION reactos/system32 FOR all) Modified: trunk/reactos/dll/win32/winemp3.acm/mpegl3.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/winemp3.acm/mpeg…
============================================================================== --- trunk/reactos/dll/win32/winemp3.acm/mpegl3.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/winemp3.acm/mpegl3.c [iso-8859-1] Sat Sep 28 15:20:19 2013 @@ -700,7 +700,7 @@ aftd->dwFormatTagIndex = 2; /* WAVE_FORMAT_MPEG is biggest */ break; } - /* fall thru */ + /* fall through */ case ACM_FORMATTAGDETAILSF_FORMATTAG: switch (aftd->dwFormatTag) { Modified: trunk/reactos/media/doc/README.WINE URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/media/doc/README.WINE?rev=…
============================================================================== --- trunk/reactos/media/doc/README.WINE [iso-8859-1] (original) +++ trunk/reactos/media/doc/README.WINE [iso-8859-1] Sat Sep 28 15:20:19 2013 @@ -200,7 +200,7 @@ reactos/dll/win32/wbemprox # Synced to Wine-1.7.1 reactos/dll/win32/wer # Autosync reactos/dll/win32/windowscodecs # Synced to Wine-1.7.1 -reactos/dll/win32/winemp3.acm # Synced to Wine-1.5.19 +reactos/dll/win32/winemp3.acm # Synced to Wine-1.7.1 reactos/dll/win32/wing32 # Out of sync reactos/dll/win32/winhttp # Synced to Wine-1.5.26 reactos/dll/win32/wininet # Synced to Wine-1.5.26
11 years, 2 months
1
0
0
0
[akhaldi] 60423: [WBEMPROX_WINETEST] * Import from Wine 1.7.1. CORE-7469
by akhaldi@svn.reactos.org
Author: akhaldi Date: Sat Sep 28 15:17:20 2013 New Revision: 60423 URL:
http://svn.reactos.org/svn/reactos?rev=60423&view=rev
Log: [WBEMPROX_WINETEST] * Import from Wine 1.7.1. CORE-7469 Added: trunk/rostests/winetests/wbemprox/ trunk/rostests/winetests/wbemprox/CMakeLists.txt (with props) trunk/rostests/winetests/wbemprox/query.c (with props) trunk/rostests/winetests/wbemprox/services.c (with props) trunk/rostests/winetests/wbemprox/testlist.c (with props) Modified: trunk/rostests/winetests/CMakeLists.txt Modified: trunk/rostests/winetests/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/CMakeLists.txt?…
============================================================================== --- trunk/rostests/winetests/CMakeLists.txt [iso-8859-1] (original) +++ trunk/rostests/winetests/CMakeLists.txt [iso-8859-1] Sat Sep 28 15:17:20 2013 @@ -95,6 +95,7 @@ add_subdirectory(uxtheme) add_subdirectory(vbscript) add_subdirectory(version) +add_subdirectory(wbemprox) add_subdirectory(windowscodecs) add_subdirectory(winhttp) add_subdirectory(wininet) Added: trunk/rostests/winetests/wbemprox/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/wbemprox/CMakeL…
============================================================================== --- trunk/rostests/winetests/wbemprox/CMakeLists.txt (added) +++ trunk/rostests/winetests/wbemprox/CMakeLists.txt [iso-8859-1] Sat Sep 28 15:17:20 2013 @@ -0,0 +1,11 @@ + +list(APPEND SOURCE + query.c + services.c + testlist.c) + +add_executable(wbemprox_winetest ${SOURCE}) +target_link_libraries(wbemprox_winetest uuid) +set_module_type(wbemprox_winetest win32cui) +add_importlibs(wbemprox_winetest oleaut32 ole32 user32 msvcrt kernel32) +add_cd_file(TARGET wbemprox_winetest DESTINATION reactos/bin FOR all) Propchange: trunk/rostests/winetests/wbemprox/CMakeLists.txt ------------------------------------------------------------------------------ svn:eol-style = native Added: trunk/rostests/winetests/wbemprox/query.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/wbemprox/query.…
============================================================================== --- trunk/rostests/winetests/wbemprox/query.c (added) +++ trunk/rostests/winetests/wbemprox/query.c [iso-8859-1] Sat Sep 28 15:17:20 2013 @@ -0,0 +1,662 @@ +/* + * Copyright 2012 Hans Leidekker for CodeWeavers + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#define COBJMACROS + +#include <stdio.h> +#include "windows.h" +#include "ocidl.h" +#include "initguid.h" +#include "objidl.h" +#include "wbemcli.h" +#include "wine/test.h" + +static const WCHAR wqlW[] = {'w','q','l',0}; + +static HRESULT exec_query( IWbemServices *services, const WCHAR *str, IEnumWbemClassObject **result ) +{ + static const WCHAR captionW[] = {'C','a','p','t','i','o','n',0}; + static const WCHAR descriptionW[] = {'D','e','s','c','r','i','p','t','i','o','n',0}; + HRESULT hr; + IWbemClassObject *obj; + BSTR wql = SysAllocString( wqlW ), query = SysAllocString( str ); + LONG flags = WBEM_FLAG_RETURN_IMMEDIATELY | WBEM_FLAG_FORWARD_ONLY; + ULONG count; + + hr = IWbemServices_ExecQuery( services, wql, query, flags, NULL, result ); + if (hr == S_OK) + { + trace("%s\n", wine_dbgstr_w(str)); + for (;;) + { + VARIANT var; + + IEnumWbemClassObject_Next( *result, WBEM_INFINITE, 1, &obj, &count ); + if (!count) break; + + if (IWbemClassObject_Get( obj, captionW, 0, &var, NULL, NULL ) == WBEM_S_NO_ERROR) + { + trace("caption: %s\n", wine_dbgstr_w(V_BSTR(&var))); + VariantClear( &var ); + } + if (IWbemClassObject_Get( obj, descriptionW, 0, &var, NULL, NULL ) == WBEM_S_NO_ERROR) + { + trace("description: %s\n", wine_dbgstr_w(V_BSTR(&var))); + VariantClear( &var ); + } + IWbemClassObject_Release( obj ); + } + } + SysFreeString( wql ); + SysFreeString( query ); + return hr; +} + +static void test_select( IWbemServices *services ) +{ + static const WCHAR emptyW[] = {0}; + static const WCHAR sqlW[] = {'S','Q','L',0}; + static const WCHAR query1[] = + {'S','E','L','E','C','T',' ','H','O','T','F','I','X','I','D',' ','F','R','O','M',' ', + 'W','i','n','3','2','_','Q','u','i','c','k','F','i','x','E','n','g','i','n','e','e','r','i','n','g',0}; + static const WCHAR query2[] = + {'S','E','L','E','C','T',' ','*',' ','F','R','O','M',' ','W','i','n','3','2','_','B','I','O','S',0}; + static const WCHAR query3[] = + {'S','E','L','E','C','T',' ','*',' ','F','R','O','M',' ','W','i','n','3','2','_', + 'L','o','g','i','c','a','l','D','i','s','k',' ','W','H','E','R','E',' ', + '\"','N','T','F','S','\"',' ','=',' ','F','i','l','e','S','y','s','t','e','m',0}; + static const WCHAR query4[] = + {'S','E','L','E','C','T',' ','a',' ','F','R','O','M',' ','b',0}; + static const WCHAR query5[] = + {'S','E','L','E','C','T',' ','a',' ','F','R','O','M',' ','W','i','n','3','2','_','B','i','o','s',0}; + static const WCHAR query6[] = + {'S','E','L','E','C','T',' ','D','e','s','c','r','i','p','t','i','o','n',' ','F','R','O','M',' ', + 'W','i','n','3','2','_','B','i','o','s',0}; + static const WCHAR query7[] = + {'S','E','L','E','C','T',' ','*',' ','F','R','O','M',' ','W','i','n','3','2','_', + 'P','r','o','c','e','s','s',' ','W','H','E','R','E',' ','C','a','p','t','i','o','n',' ', + 'L','I','K','E',' ','\'','%','%','R','E','G','E','D','I','T','%','\'',0}; + static const WCHAR query8[] = + {'S','E','L','E','C','T',' ','*',' ','F','R','O','M',' ','W','i','n','3','2','_', + 'D','i','s','k','D','r','i','v','e',' ','W','H','E','R','E',' ','D','e','v','i','c','e','I','D','=', + '\"','\\','\\','\\','\\','.','\\','\\','P','H','Y','S','I','C','A','L','D','R','I','V','E','0','\"',0}; + static const WCHAR *test[] = { query1, query2, query3, query4, query5, query6, query7, query8 }; + HRESULT hr; + IEnumWbemClassObject *result; + BSTR wql = SysAllocString( wqlW ); + BSTR sql = SysAllocString( sqlW ); + BSTR query = SysAllocString( query1 ); + UINT i; + + hr = IWbemServices_ExecQuery( services, NULL, NULL, 0, NULL, &result ); + ok( hr == WBEM_E_INVALID_PARAMETER, "query failed %08x\n", hr ); + + hr = IWbemServices_ExecQuery( services, NULL, query, 0, NULL, &result ); + ok( hr == WBEM_E_INVALID_PARAMETER, "query failed %08x\n", hr ); + + hr = IWbemServices_ExecQuery( services, wql, NULL, 0, NULL, &result ); + ok( hr == WBEM_E_INVALID_PARAMETER, "query failed %08x\n", hr ); + + hr = IWbemServices_ExecQuery( services, sql, query, 0, NULL, &result ); + ok( hr == WBEM_E_INVALID_QUERY_TYPE, "query failed %08x\n", hr ); + + hr = IWbemServices_ExecQuery( services, sql, NULL, 0, NULL, &result ); + ok( hr == WBEM_E_INVALID_PARAMETER, "query failed %08x\n", hr ); + + SysFreeString( query ); + query = SysAllocString( emptyW ); + hr = IWbemServices_ExecQuery( services, wql, query, 0, NULL, &result ); + ok( hr == WBEM_E_INVALID_PARAMETER, "query failed %08x\n", hr ); + + for (i = 0; i < sizeof(test)/sizeof(test[0]); i++) + { + hr = exec_query( services, test[i], &result ); + ok( hr == S_OK, "query %u failed: %08x\n", i, hr ); + if (result) IEnumWbemClassObject_Release( result ); + } + + SysFreeString( wql ); + SysFreeString( sql ); + SysFreeString( query ); +} + +static void test_Win32_Service( IWbemServices *services ) +{ + static const WCHAR returnvalueW[] = {'R','e','t','u','r','n','V','a','l','u','e',0}; + static const WCHAR pauseserviceW[] = {'P','a','u','s','e','S','e','r','v','i','c','e',0}; + static const WCHAR resumeserviceW[] = {'R','e','s','u','m','e','S','e','r','v','i','c','e',0}; + static const WCHAR startserviceW[] = {'S','t','a','r','t','S','e','r','v','i','c','e',0}; + static const WCHAR stopserviceW[] = {'S','t','o','p','S','e','r','v','i','c','e',0}; + static const WCHAR stateW[] = {'S','t','a','t','e',0}; + static const WCHAR stoppedW[] = {'S','t','o','p','p','e','d',0}; + static const WCHAR serviceW[] = {'W','i','n','3','2','_','S','e','r','v','i','c','e','.', + 'N','a','m','e','=','"','S','p','o','o','l','e','r','"',0}; + static const WCHAR emptyW[] = {0}; + BSTR class = SysAllocString( serviceW ), empty = SysAllocString( emptyW ), method; + IWbemClassObject *service, *out; + VARIANT state, retval; + CIMTYPE type; + HRESULT hr; + + hr = IWbemServices_GetObject( services, class, 0, NULL, &service, NULL ); + if (hr != S_OK) + { + win_skip( "Win32_Service not available\n" ); + return; + } + type = 0xdeadbeef; + VariantInit( &state ); + hr = IWbemClassObject_Get( service, stateW, 0, &state, &type, NULL ); + ok( hr == S_OK, "failed to get service state %08x\n", hr ); + ok( V_VT( &state ) == VT_BSTR, "unexpected variant type 0x%x\n", V_VT( &state ) ); + ok( type == CIM_STRING, "unexpected type 0x%x\n", type ); + + if (!lstrcmpW( V_BSTR( &state ), stoppedW )) + { + out = NULL; + method = SysAllocString( startserviceW ); + hr = IWbemServices_ExecMethod( services, class, method, 0, NULL, NULL, &out, NULL ); + ok( hr == S_OK, "failed to execute method %08x\n", hr ); + SysFreeString( method ); + + VariantInit( &retval ); + hr = IWbemClassObject_Get( out, returnvalueW, 0, &retval, NULL, NULL ); + ok( hr == S_OK, "failed to get return value %08x\n", hr ); + ok( !V_I4( &retval ), "unexpected error %u\n", V_UI4( &retval ) ); + IWbemClassObject_Release( out ); + } + out = NULL; + method = SysAllocString( pauseserviceW ); + hr = IWbemServices_ExecMethod( services, class, method, 0, NULL, NULL, &out, NULL ); + ok( hr == S_OK, "failed to execute method %08x\n", hr ); + SysFreeString( method ); + + VariantInit( &retval ); + hr = IWbemClassObject_Get( out, returnvalueW, 0, &retval, NULL, NULL ); + ok( hr == S_OK, "failed to get return value %08x\n", hr ); + ok( V_I4( &retval ), "unexpected success\n" ); + IWbemClassObject_Release( out ); + + out = NULL; + method = SysAllocString( resumeserviceW ); + hr = IWbemServices_ExecMethod( services, class, method, 0, NULL, NULL, &out, NULL ); + ok( hr == S_OK, "failed to execute method %08x\n", hr ); + SysFreeString( method ); + + VariantInit( &retval ); + hr = IWbemClassObject_Get( out, returnvalueW, 0, &retval, NULL, NULL ); + ok( hr == S_OK, "failed to get return value %08x\n", hr ); + ok( V_I4( &retval ), "unexpected success\n" ); + IWbemClassObject_Release( out ); + + if (!lstrcmpW( V_BSTR( &state ), stoppedW )) + { + out = NULL; + method = SysAllocString( stopserviceW ); + hr = IWbemServices_ExecMethod( services, class, method, 0, NULL, NULL, &out, NULL ); + ok( hr == S_OK, "failed to execute method %08x\n", hr ); + SysFreeString( method ); + + VariantInit( &retval ); + hr = IWbemClassObject_Get( out, returnvalueW, 0, &retval, NULL, NULL ); + ok( hr == S_OK, "failed to get return value %08x\n", hr ); + ok( !V_I4( &retval ), "unexpected error %u\n", V_UI4( &retval ) ); + IWbemClassObject_Release( out ); + } + VariantClear( &state ); + IWbemClassObject_Release( service ); + + service = NULL; + hr = IWbemServices_GetObject( services, NULL, 0, NULL, &service, NULL ); + ok( hr == S_OK, "got %08x\n", hr ); + if (service) IWbemClassObject_Release( service ); + + service = NULL; + hr = IWbemServices_GetObject( services, empty, 0, NULL, &service, NULL ); + ok( hr == S_OK, "got %08x\n", hr ); + if (service) IWbemClassObject_Release( service ); + + SysFreeString( empty ); + SysFreeString( class ); +} + +static void test_Win32_Process( IWbemServices *services ) +{ + static const WCHAR returnvalueW[] = {'R','e','t','u','r','n','V','a','l','u','e',0}; + static const WCHAR getownerW[] = {'G','e','t','O','w','n','e','r',0}; + static const WCHAR userW[] = {'U','s','e','r',0}; + static const WCHAR domainW[] = {'D','o','m','a','i','n',0}; + static const WCHAR processW[] = {'W','i','n','3','2','_','P','r','o','c','e','s','s',0}; + static const WCHAR idW[] = {'I','D',0}; + static const WCHAR fmtW[] = {'W','i','n','3','2','_','P','r','o','c','e','s','s','.', + 'H','a','n','d','l','e','=','"','%','u','"',0}; + static const LONG expected_flavor = WBEM_FLAVOR_FLAG_PROPAGATE_TO_INSTANCE | + WBEM_FLAVOR_NOT_OVERRIDABLE | + WBEM_FLAVOR_ORIGIN_PROPAGATED; + BSTR class, method; + IWbemClassObject *process, *out; + IWbemQualifierSet *qualifiers; + VARIANT user, domain, retval, val; + LONG flavor; + CIMTYPE type; + HRESULT hr; + + class = SysAllocString( processW ); + hr = IWbemServices_GetObject( services, class, 0, NULL, &process, NULL ); + SysFreeString( class ); + if (hr != S_OK) + { + win_skip( "Win32_Process not available\n" ); + return; + } + hr = IWbemClassObject_GetMethod( process, getownerW, 0, NULL, NULL ); + ok( hr == S_OK, "failed to get GetOwner method %08x\n", hr ); + + out = NULL; + method = SysAllocString( getownerW ); + class = SysAllocStringLen( NULL, sizeof(fmtW)/sizeof(fmtW[0]) + 10 ); + wsprintfW( class, fmtW, GetCurrentProcessId() ); + hr = IWbemServices_ExecMethod( services, class, method, 0, NULL, NULL, &out, NULL ); + ok( hr == S_OK, "failed to execute method %08x\n", hr ); + SysFreeString( method ); + SysFreeString( class ); + + type = 0xdeadbeef; + VariantInit( &retval ); + hr = IWbemClassObject_Get( out, returnvalueW, 0, &retval, &type, NULL ); + ok( hr == S_OK, "failed to get return value %08x\n", hr ); + ok( V_VT( &retval ) == VT_I4, "unexpected variant type 0x%x\n", V_VT( &retval ) ); + ok( !V_I4( &retval ), "unexpected error %u\n", V_I4( &retval ) ); + ok( type == CIM_UINT32, "unexpected type 0x%x\n", type ); + + type = 0xdeadbeef; + VariantInit( &user ); + hr = IWbemClassObject_Get( out, userW, 0, &user, &type, NULL ); + ok( hr == S_OK, "failed to get user %08x\n", hr ); + ok( V_VT( &user ) == VT_BSTR, "unexpected variant type 0x%x\n", V_VT( &user ) ); + ok( type == CIM_STRING, "unexpected type 0x%x\n", type ); + trace("%s\n", wine_dbgstr_w(V_BSTR(&user))); + + type = 0xdeadbeef; + VariantInit( &domain ); + hr = IWbemClassObject_Get( out, domainW, 0, &domain, &type, NULL ); + ok( hr == S_OK, "failed to get domain %08x\n", hr ); + ok( V_VT( &domain ) == VT_BSTR, "unexpected variant type 0x%x\n", V_VT( &domain ) ); + ok( type == CIM_STRING, "unexpected type 0x%x\n", type ); + trace("%s\n", wine_dbgstr_w(V_BSTR(&domain))); + + hr = IWbemClassObject_GetPropertyQualifierSet( out, userW, &qualifiers ); + ok( hr == S_OK, "failed to get qualifier set %08x\n", hr ); + + flavor = -1; + V_I4(&val) = -1; + V_VT(&val) = VT_ERROR; + hr = IWbemQualifierSet_Get( qualifiers, idW, 0, &val, &flavor ); + ok( hr == S_OK, "got %08x\n", hr ); + ok( flavor == expected_flavor, "got %d\n", flavor ); + ok( V_VT(&val) == VT_I4, "got %u\n", V_VT(&val) ); + ok( V_I4(&val) == 0, "got %u\n", V_I4(&val) ); + VariantClear( &val ); + + IWbemQualifierSet_Release( qualifiers ); + hr = IWbemClassObject_GetPropertyQualifierSet( out, domainW, &qualifiers ); + ok( hr == S_OK, "failed to get qualifier set %08x\n", hr ); + + flavor = -1; + V_I4(&val) = -1; + V_VT(&val) = VT_ERROR; + hr = IWbemQualifierSet_Get( qualifiers, idW, 0, &val, &flavor ); + ok( hr == S_OK, "got %08x\n", hr ); + ok( flavor == expected_flavor, "got %d\n", flavor ); + ok( V_VT(&val) == VT_I4, "got %u\n", V_VT(&val) ); + ok( V_I4(&val) == 1, "got %u\n", V_I4(&val) ); + VariantClear( &val ); + + IWbemQualifierSet_Release( qualifiers ); + hr = IWbemClassObject_GetPropertyQualifierSet( out, returnvalueW, &qualifiers ); + ok( hr == S_OK, "failed to get qualifier set %08x\n", hr ); + + hr = IWbemQualifierSet_Get( qualifiers, idW, 0, &val, &flavor ); + ok( hr == WBEM_E_NOT_FOUND, "got %08x\n", hr ); + + IWbemQualifierSet_Release( qualifiers ); + VariantClear( &user ); + VariantClear( &domain ); + IWbemClassObject_Release( out ); +} + +static void test_StdRegProv( IWbemServices *services ) +{ + static const WCHAR enumkeyW[] = {'E','n','u','m','K','e','y',0}; + static const WCHAR enumvaluesW[] = {'E','n','u','m','V','a','l','u','e','s',0}; + static const WCHAR getstringvalueW[] = {'G','e','t','S','t','r','i','n','g','V','a','l','u','e',0}; + static const WCHAR stdregprovW[] = {'S','t','d','R','e','g','P','r','o','v',0}; + static const WCHAR defkeyW[] = {'h','D','e','f','K','e','y',0}; + static const WCHAR subkeynameW[] = {'s','S','u','b','K','e','y','N','a','m','e',0}; + static const WCHAR returnvalueW[] = {'R','e','t','u','r','n','V','a','l','u','e',0}; + static const WCHAR namesW[] = {'s','N','a','m','e','s',0}; + static const WCHAR typesW[] = {'T','y','p','e','s',0}; + static const WCHAR valueW[] = {'s','V','a','l','u','e',0}; + static const WCHAR valuenameW[] = {'s','V','a','l','u','e','N','a','m','e',0}; + static const WCHAR programfilesW[] = {'P','r','o','g','r','a','m','F','i','l','e','s','D','i','r',0}; + static const WCHAR windowsW[] = + {'S','o','f','t','w','a','r','e','\\','M','i','c','r','o','s','o','f','t','\\', + 'W','i','n','d','o','w','s','\\','C','u','r','r','e','n','t','V','e','r','s','i','o','n',0}; + BSTR class = SysAllocString( stdregprovW ), method; + IWbemClassObject *reg, *sig_in, *in, *out; + VARIANT defkey, subkey, retval, names, types, value, valuename; + CIMTYPE type; + HRESULT hr; + + hr = IWbemServices_GetObject( services, class, 0, NULL, ®, NULL ); + if (hr != S_OK) + { + win_skip( "StdRegProv not available\n" ); + return; + } + hr = IWbemClassObject_GetMethod( reg, enumkeyW, 0, &sig_in, NULL ); + ok( hr == S_OK, "failed to get EnumKey method %08x\n", hr ); + + hr = IWbemClassObject_SpawnInstance( sig_in, 0, &in ); + ok( hr == S_OK, "failed to spawn instance %08x\n", hr ); + + V_VT( &defkey ) = VT_I4; + V_I4( &defkey ) = 0x80000002; + hr = IWbemClassObject_Put( in, defkeyW, 0, &defkey, 0 ); + ok( hr == S_OK, "failed to set root %08x\n", hr ); + + V_VT( &subkey ) = VT_BSTR; + V_BSTR( &subkey ) = SysAllocString( windowsW ); + hr = IWbemClassObject_Put( in, subkeynameW, 0, &subkey, 0 ); + ok( hr == S_OK, "failed to set subkey %08x\n", hr ); + + out = NULL; + method = SysAllocString( enumkeyW ); + hr = IWbemServices_ExecMethod( services, class, method, 0, NULL, in, &out, NULL ); + ok( hr == S_OK, "failed to execute method %08x\n", hr ); + SysFreeString( method ); + + type = 0xdeadbeef; + VariantInit( &retval ); + hr = IWbemClassObject_Get( out, returnvalueW, 0, &retval, &type, NULL ); + ok( hr == S_OK, "failed to get return value %08x\n", hr ); + ok( V_VT( &retval ) == VT_I4, "unexpected variant type 0x%x\n", V_VT( &retval ) ); + ok( !V_I4( &retval ), "unexpected error %u\n", V_UI4( &retval ) ); + ok( type == CIM_UINT32, "unexpected type 0x%x\n", type ); + + type = 0xdeadbeef; + VariantInit( &names ); + hr = IWbemClassObject_Get( out, namesW, 0, &names, &type, NULL ); + ok( hr == S_OK, "failed to get names %08x\n", hr ); + ok( V_VT( &names ) == (VT_BSTR|VT_ARRAY), "unexpected variant type 0x%x\n", V_VT( &names ) ); + ok( type == (CIM_STRING|CIM_FLAG_ARRAY), "unexpected type 0x%x\n", type ); + + VariantClear( &names ); + VariantClear( &subkey ); + IWbemClassObject_Release( in ); + IWbemClassObject_Release( out ); + IWbemClassObject_Release( sig_in ); + + hr = IWbemClassObject_GetMethod( reg, enumvaluesW, 0, &sig_in, NULL ); + ok( hr == S_OK, "failed to get EnumValues method %08x\n", hr ); + + hr = IWbemClassObject_SpawnInstance( sig_in, 0, &in ); + ok( hr == S_OK, "failed to spawn instance %08x\n", hr ); + + V_VT( &defkey ) = VT_I4; + V_I4( &defkey ) = 0x80000002; + hr = IWbemClassObject_Put( in, defkeyW, 0, &defkey, 0 ); + ok( hr == S_OK, "failed to set root %08x\n", hr ); + + V_VT( &subkey ) = VT_BSTR; + V_BSTR( &subkey ) = SysAllocString( windowsW ); + hr = IWbemClassObject_Put( in, subkeynameW, 0, &subkey, 0 ); + ok( hr == S_OK, "failed to set subkey %08x\n", hr ); + + out = NULL; + method = SysAllocString( enumvaluesW ); + hr = IWbemServices_ExecMethod( services, class, method, 0, NULL, in, &out, NULL ); + ok( hr == S_OK, "failed to execute method %08x\n", hr ); + SysFreeString( method ); + + type = 0xdeadbeef; + VariantInit( &retval ); + hr = IWbemClassObject_Get( out, returnvalueW, 0, &retval, &type, NULL ); + ok( hr == S_OK, "failed to get return value %08x\n", hr ); + ok( V_VT( &retval ) == VT_I4, "unexpected variant type 0x%x\n", V_VT( &retval ) ); + ok( !V_I4( &retval ), "unexpected error %u\n", V_I4( &retval ) ); + ok( type == CIM_UINT32, "unexpected type 0x%x\n", type ); + + type = 0xdeadbeef; + VariantInit( &names ); + hr = IWbemClassObject_Get( out, namesW, 0, &names, &type, NULL ); + ok( hr == S_OK, "failed to get names %08x\n", hr ); + ok( V_VT( &names ) == (VT_BSTR|VT_ARRAY), "unexpected variant type 0x%x\n", V_VT( &names ) ); + ok( type == (CIM_STRING|CIM_FLAG_ARRAY), "unexpected type 0x%x\n", type ); + + type = 0xdeadbeef; + VariantInit( &types ); + hr = IWbemClassObject_Get( out, typesW, 0, &types, &type, NULL ); + ok( hr == S_OK, "failed to get names %08x\n", hr ); + ok( V_VT( &types ) == (VT_I4|VT_ARRAY), "unexpected variant type 0x%x\n", V_VT( &types ) ); + ok( type == (CIM_SINT32|CIM_FLAG_ARRAY), "unexpected type 0x%x\n", type ); + + VariantClear( &types ); + VariantClear( &names ); + VariantClear( &subkey ); + IWbemClassObject_Release( in ); + IWbemClassObject_Release( out ); + IWbemClassObject_Release( sig_in ); + + hr = IWbemClassObject_GetMethod( reg, getstringvalueW, 0, &sig_in, NULL ); + ok( hr == S_OK, "failed to get GetStringValue method %08x\n", hr ); + + hr = IWbemClassObject_SpawnInstance( sig_in, 0, &in ); + ok( hr == S_OK, "failed to spawn instance %08x\n", hr ); + + V_VT( &defkey ) = VT_I4; + V_I4( &defkey ) = 0x80000002; + hr = IWbemClassObject_Put( in, defkeyW, 0, &defkey, 0 ); + ok( hr == S_OK, "failed to set root %08x\n", hr ); + + V_VT( &subkey ) = VT_BSTR; + V_BSTR( &subkey ) = SysAllocString( windowsW ); + hr = IWbemClassObject_Put( in, subkeynameW, 0, &subkey, 0 ); + ok( hr == S_OK, "failed to set subkey %08x\n", hr ); + + V_VT( &valuename ) = VT_BSTR; + V_BSTR( &valuename ) = SysAllocString( programfilesW ); + hr = IWbemClassObject_Put( in, valuenameW, 0, &valuename, 0 ); + ok( hr == S_OK, "failed to set value name %08x\n", hr ); + + out = NULL; + method = SysAllocString( getstringvalueW ); + hr = IWbemServices_ExecMethod( services, class, method, 0, NULL, in, &out, NULL ); + ok( hr == S_OK, "failed to execute method %08x\n", hr ); + SysFreeString( method ); + + type = 0xdeadbeef; + VariantInit( &retval ); + hr = IWbemClassObject_Get( out, returnvalueW, 0, &retval, &type, NULL ); + ok( hr == S_OK, "failed to get return value %08x\n", hr ); + ok( V_VT( &retval ) == VT_I4, "unexpected variant type 0x%x\n", V_VT( &retval ) ); + ok( !V_I4( &retval ), "unexpected error %u\n", V_I4( &retval ) ); + ok( type == CIM_UINT32, "unexpected type 0x%x\n", type ); + + type = 0xdeadbeef; + VariantInit( &value ); + hr = IWbemClassObject_Get( out, valueW, 0, &value, &type, NULL ); + ok( hr == S_OK, "failed to get value %08x\n", hr ); + ok( V_VT( &value ) == VT_BSTR, "unexpected variant type 0x%x\n", V_VT( &value ) ); + ok( type == CIM_STRING, "unexpected type 0x%x\n", type ); + + VariantClear( &value ); + VariantClear( &valuename ); + VariantClear( &subkey ); + IWbemClassObject_Release( in ); + IWbemClassObject_Release( out ); + IWbemClassObject_Release( sig_in ); + + IWbemClassObject_Release( reg ); + SysFreeString( class ); +} + +static HRESULT WINAPI sink_QueryInterface( + IWbemObjectSink *iface, REFIID riid, void **ppv ) +{ + *ppv = NULL; + if (IsEqualGUID( &IID_IUnknown, riid ) || IsEqualGUID( &IID_IWbemObjectSink, riid )) + { + *ppv = iface; + IWbemObjectSink_AddRef( iface ); + return S_OK; + } + return E_NOINTERFACE; +} + +static ULONG sink_refs; + +static ULONG WINAPI sink_AddRef( + IWbemObjectSink *iface ) +{ + return ++sink_refs; +} + +static ULONG WINAPI sink_Release( + IWbemObjectSink *iface ) +{ + return --sink_refs; +} + +static HRESULT WINAPI sink_Indicate( + IWbemObjectSink *iface, LONG count, IWbemClassObject **objects ) +{ + trace("Indicate: %d, %p\n", count, objects); + return S_OK; +} + +static HRESULT WINAPI sink_SetStatus( + IWbemObjectSink *iface, LONG flags, HRESULT hresult, BSTR str_param, IWbemClassObject *obj_param ) +{ + trace("SetStatus: %08x, %08x, %s, %p\n", flags, hresult, wine_dbgstr_w(str_param), obj_param); + return S_OK; +} + +static IWbemObjectSinkVtbl sink_vtbl = +{ + sink_QueryInterface, + sink_AddRef, + sink_Release, + sink_Indicate, + sink_SetStatus +}; + +static IWbemObjectSink sink = { &sink_vtbl }; + +static void test_notification_query_async( IWbemServices *services ) +{ + static const WCHAR queryW[] = + {'S','E','L','E','C','T',' ','*',' ','F','R','O','M',' ','W','i','n','3','2','_', + 'D','e','v','i','c','e','C','h','a','n','g','e','E','v','e','n','t',0}; + BSTR wql = SysAllocString( wqlW ), query = SysAllocString( queryW ); + ULONG prev_sink_refs; + HRESULT hr; + + hr = IWbemServices_ExecNotificationQueryAsync( services, wql, query, 0, NULL, NULL ); + ok( hr == WBEM_E_INVALID_PARAMETER, "got %08x\n", hr ); + + prev_sink_refs = sink_refs; + hr = IWbemServices_ExecNotificationQueryAsync( services, wql, query, 0, NULL, &sink ); + ok( hr == S_OK || broken(hr == WBEM_E_NOT_FOUND), "got %08x\n", hr ); + ok( sink_refs > prev_sink_refs || broken(!sink_refs), "got %u refs\n", sink_refs ); + + hr = IWbemServices_CancelAsyncCall( services, &sink ); + ok( hr == S_OK || broken(hr == WBEM_E_NOT_FOUND), "got %08x\n", hr ); + + SysFreeString( wql ); + SysFreeString( query ); +} + +static void test_query_async( IWbemServices *services ) +{ + static const WCHAR queryW[] = + {'S','E','L','E','C','T',' ','*',' ','F','R','O','M',' ','W','i','n','3','2','_', + 'P','r','o','c','e','s','s',0}; + BSTR wql = SysAllocString( wqlW ), query = SysAllocString( queryW ); + HRESULT hr; + + hr = IWbemServices_ExecQueryAsync( services, wql, query, 0, NULL, NULL ); + ok( hr == WBEM_E_INVALID_PARAMETER, "got %08x\n", hr ); + + hr = IWbemServices_ExecQueryAsync( services, wql, query, 0, NULL, &sink ); + ok( hr == S_OK || broken(hr == WBEM_E_NOT_FOUND), "got %08x\n", hr ); + + hr = IWbemServices_CancelAsyncCall( services, NULL ); + ok( hr == WBEM_E_INVALID_PARAMETER, "got %08x\n", hr ); + + hr = IWbemServices_CancelAsyncCall( services, &sink ); + ok( hr == S_OK, "got %08x\n", hr ); + + SysFreeString( wql ); + SysFreeString( query ); +} + +START_TEST(query) +{ + static const WCHAR cimv2W[] = {'R','O','O','T','\\','C','I','M','V','2',0}; + BSTR path = SysAllocString( cimv2W ); + IWbemLocator *locator; + IWbemServices *services; + HRESULT hr; + + CoInitialize( NULL ); + CoInitializeSecurity( NULL, -1, NULL, NULL, RPC_C_AUTHN_LEVEL_DEFAULT, + RPC_C_IMP_LEVEL_IMPERSONATE, NULL, EOAC_NONE, NULL ); + hr = CoCreateInstance( &CLSID_WbemLocator, NULL, CLSCTX_INPROC_SERVER, &IID_IWbemLocator, + (void **)&locator ); + if (hr != S_OK) + { + win_skip("can't create instance of WbemLocator\n"); + return; + } + hr = IWbemLocator_ConnectServer( locator, path, NULL, NULL, NULL, 0, NULL, NULL, &services ); + ok( hr == S_OK, "failed to get IWbemServices interface %08x\n", hr ); + + hr = CoSetProxyBlanket( (IUnknown *)services, RPC_C_AUTHN_WINNT, RPC_C_AUTHZ_NONE, NULL, + RPC_C_AUTHN_LEVEL_CALL, RPC_C_IMP_LEVEL_IMPERSONATE, NULL, EOAC_NONE ); + ok( hr == S_OK, "failed to set proxy blanket %08x\n", hr ); + + if (!winetest_interactive) + { + skip("test_select( services ), ROSTESTS-120\n"); + } + else + { + test_select( services ); + } + test_Win32_Process( services ); + test_Win32_Service( services ); + test_StdRegProv( services ); + test_notification_query_async( services ); + test_query_async( services ); + + SysFreeString( path ); + IWbemServices_Release( services ); + IWbemLocator_Release( locator ); + CoUninitialize(); +} Propchange: trunk/rostests/winetests/wbemprox/query.c ------------------------------------------------------------------------------ svn:eol-style = native Added: trunk/rostests/winetests/wbemprox/services.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/wbemprox/servic…
============================================================================== --- trunk/rostests/winetests/wbemprox/services.c (added) +++ trunk/rostests/winetests/wbemprox/services.c [iso-8859-1] Sat Sep 28 15:17:20 2013 @@ -0,0 +1,185 @@ +/* + * Copyright 2012 Hans Leidekker for CodeWeavers + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#define COBJMACROS + +#include <stdio.h> +#include "windows.h" +#include "objidl.h" +#include "wbemcli.h" +#include "wine/test.h" + +static void test_IClientSecurity(void) +{ + static const WCHAR rootW[] = {'R','O','O','T','\\','C','I','M','V','2',0}; + HRESULT hr; + IWbemLocator *locator; + IWbemServices *services; + IClientSecurity *security; + BSTR path = SysAllocString( rootW ); + ULONG refs; + + hr = CoCreateInstance( &CLSID_WbemLocator, NULL, CLSCTX_INPROC_SERVER, &IID_IWbemLocator, (void **)&locator ); + if (hr != S_OK) + { + win_skip("can't create instance of WbemLocator\n"); + return; + } + ok( hr == S_OK, "failed to create IWbemLocator interface %08x\n", hr ); + + refs = IWbemLocator_Release( locator ); + ok( refs == 0, "unexpected refcount %u\n", refs ); + + hr = CoCreateInstance( &CLSID_WbemLocator, NULL, CLSCTX_INPROC_SERVER, &IID_IWbemLocator, (void **)&locator ); + ok( hr == S_OK, "failed to create IWbemLocator interface %08x\n", hr ); + + hr = IWbemLocator_ConnectServer( locator, path, NULL, NULL, NULL, 0, NULL, NULL, &services ); + ok( hr == S_OK, "failed to get IWbemServices interface %08x\n", hr ); + + refs = IWbemServices_Release( services ); + ok( refs == 0, "unexpected refcount %u\n", refs ); + + hr = IWbemLocator_ConnectServer( locator, path, NULL, NULL, NULL, 0, NULL, NULL, &services ); + ok( hr == S_OK, "failed to get IWbemServices interface %08x\n", hr ); + + hr = IWbemServices_QueryInterface( services, &IID_IClientSecurity, (void **)&security ); + ok( hr == S_OK, "failed to query IClientSecurity interface %08x\n", hr ); + ok( (void *)services != (void *)security, "expected pointers to be different\n" ); + + refs = IClientSecurity_Release( security ); + ok( refs == 1, "unexpected refcount %u\n", refs ); + + refs = IWbemServices_Release( services ); + ok( refs == 0, "unexpected refcount %u\n", refs ); + + hr = IWbemLocator_ConnectServer( locator, path, NULL, NULL, NULL, 0, NULL, NULL, &services ); + ok( hr == S_OK, "failed to get IWbemServices interface %08x\n", hr ); + + hr = IWbemServices_QueryInterface( services, &IID_IClientSecurity, (void **)&security ); + ok( hr == S_OK, "failed to query IClientSecurity interface %08x\n", hr ); + ok( (void *)services != (void *)security, "expected pointers to be different\n" ); + + refs = IWbemServices_Release( services ); + todo_wine ok( refs == 1, "unexpected refcount %u\n", refs ); + + refs = IClientSecurity_Release( security ); + todo_wine ok( refs == 0, "unexpected refcount %u\n", refs ); + + IWbemLocator_Release( locator ); + SysFreeString( path ); +} + +static void test_IWbemLocator(void) +{ + static const WCHAR path0W[] = {0}; + static const WCHAR path1W[] = {'\\',0}; + static const WCHAR path2W[] = {'\\','\\',0}; + static const WCHAR path3W[] = {'\\','\\','.',0}; + static const WCHAR path4W[] = {'\\','\\','.','\\',0}; + static const WCHAR path5W[] = {'\\','R','O','O','T',0}; + static const WCHAR path6W[] = {'\\','\\','R','O','O','T',0}; + static const WCHAR path7W[] = {'\\','\\','.','R','O','O','T',0}; + static const WCHAR path8W[] = {'\\','\\','.','\\','N','O','N','E',0}; + static const WCHAR path9W[] = {'\\','\\','.','\\','R','O','O','T',0}; + static const WCHAR path10W[] = {'\\','\\','\\','.','\\','R','O','O','T',0}; + static const WCHAR path11W[] = {'\\','/','.','\\','R','O','O','T',0}; + static const WCHAR path12W[] = {'/','/','.','\\','R','O','O','T',0}; + static const WCHAR path13W[] = {'\\','\\','.','/','R','O','O','T',0}; + static const WCHAR path14W[] = {'/','/','.','/','R','O','O','T',0}; + static const WCHAR path15W[] = {'N','O','N','E',0}; + static const WCHAR path16W[] = {'R','O','O','T',0}; + static const WCHAR path17W[] = {'R','O','O','T','\\','N','O','N','E',0}; + static const WCHAR path18W[] = {'R','O','O','T','\\','C','I','M','V','2',0}; + static const WCHAR path19W[] = {'R','O','O','T','\\','\\','C','I','M','V','2',0}; + static const WCHAR path20W[] = {'R','O','O','T','\\','C','I','M','V','2','\\',0}; + static const WCHAR path21W[] = {'R','O','O','T','/','C','I','M','V','2',0}; + static const WCHAR path22W[] = {'r','o','o','t','\\','d','e','f','a','u','l','t',0}; + static const WCHAR path23W[] = {'r','o','o','t','\\','c','i','m','v','0',0}; + static const WCHAR path24W[] = {'r','o','o','t','\\','c','i','m','v','1',0}; + static const struct + { + const WCHAR *path; + HRESULT result; + int todo; + HRESULT result_broken; + } + test[] = + { + { path0W, WBEM_E_INVALID_NAMESPACE }, + { path1W, WBEM_E_INVALID_NAMESPACE }, + { path2W, WBEM_E_INVALID_NAMESPACE }, + { path3W, WBEM_E_INVALID_NAMESPACE }, + { path4W, WBEM_E_INVALID_NAMESPACE, 0, WBEM_E_INVALID_PARAMETER }, + { path5W, WBEM_E_INVALID_NAMESPACE }, + { path6W, 0x800706ba, 1 }, + { path7W, 0x800706ba, 1 }, + { path8W, WBEM_E_INVALID_NAMESPACE }, + { path9W, S_OK }, + { path10W, WBEM_E_INVALID_PARAMETER }, + { path11W, S_OK }, + { path12W, S_OK }, + { path13W, S_OK }, + { path14W, S_OK }, + { path15W, WBEM_E_INVALID_NAMESPACE }, + { path16W, S_OK }, + { path17W, WBEM_E_INVALID_NAMESPACE }, + { path18W, S_OK }, + { path19W, WBEM_E_INVALID_NAMESPACE }, + { path20W, WBEM_E_INVALID_NAMESPACE }, + { path21W, S_OK }, + { path22W, S_OK }, + { path23W, WBEM_E_INVALID_NAMESPACE }, + { path24W, WBEM_E_INVALID_NAMESPACE } + }; + IWbemLocator *locator; + IWbemServices *services; + unsigned int i; + HRESULT hr; + BSTR resource; + + hr = CoCreateInstance( &CLSID_WbemLocator, NULL, CLSCTX_INPROC_SERVER, &IID_IWbemLocator, (void **)&locator ); + if (hr != S_OK) + { + win_skip("can't create instance of WbemLocator\n"); + return; + } + ok( hr == S_OK, "failed to create IWbemLocator interface %08x\n", hr ); + + for (i = 0; i < sizeof(test) / sizeof(test[0]); i++) + { + resource = SysAllocString( test[i].path ); + hr = IWbemLocator_ConnectServer( locator, resource, NULL, NULL, NULL, 0, NULL, NULL, &services ); + if (test[i].todo) todo_wine + ok( hr == test[i].result || broken(hr == test[i].result_broken), + "%u: expected %08x got %08x\n", i, test[i].result, hr ); + else + ok( hr == test[i].result || broken(hr == test[i].result_broken), + "%u: expected %08x got %08x\n", i, test[i].result, hr ); + SysFreeString( resource ); + if (hr == S_OK) IWbemServices_Release( services ); + } + IWbemLocator_Release( locator ); +} + +START_TEST(services) +{ + CoInitialize( NULL ); + test_IClientSecurity(); + test_IWbemLocator(); + CoUninitialize(); +} Propchange: trunk/rostests/winetests/wbemprox/services.c ------------------------------------------------------------------------------ svn:eol-style = native Added: trunk/rostests/winetests/wbemprox/testlist.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/wbemprox/testli…
============================================================================== --- trunk/rostests/winetests/wbemprox/testlist.c (added) +++ trunk/rostests/winetests/wbemprox/testlist.c [iso-8859-1] Sat Sep 28 15:17:20 2013 @@ -0,0 +1,14 @@ +/* Automatically generated file; DO NOT EDIT!! */ + +#define STANDALONE +#include <wine/test.h> + +extern void func_query(void); +extern void func_services(void); + +const struct test winetest_testlist[] = +{ + { "query", func_query }, + { "services", func_services }, + { 0, 0 } +}; Propchange: trunk/rostests/winetests/wbemprox/testlist.c ------------------------------------------------------------------------------ svn:eol-style = native
11 years, 2 months
1
0
0
0
[akhaldi] 60422: [WBEMPROX] * Sync with Wine 1.7.1. CORE-7469
by akhaldi@svn.reactos.org
Author: akhaldi Date: Sat Sep 28 15:14:31 2013 New Revision: 60422 URL:
http://svn.reactos.org/svn/reactos?rev=60422&view=rev
Log: [WBEMPROX] * Sync with Wine 1.7.1. CORE-7469 Modified: trunk/reactos/dll/win32/wbemprox/CMakeLists.txt trunk/reactos/dll/win32/wbemprox/builtin.c trunk/reactos/dll/win32/wbemprox/class.c trunk/reactos/dll/win32/wbemprox/main.c trunk/reactos/dll/win32/wbemprox/process.c trunk/reactos/dll/win32/wbemprox/query.c trunk/reactos/dll/win32/wbemprox/reg.c trunk/reactos/dll/win32/wbemprox/services.c trunk/reactos/dll/win32/wbemprox/table.c trunk/reactos/dll/win32/wbemprox/wbemlocator.c trunk/reactos/dll/win32/wbemprox/wbemprox_private.h trunk/reactos/dll/win32/wbemprox/wql.tab.c trunk/reactos/dll/win32/wbemprox/wql.y trunk/reactos/media/doc/README.WINE [This mail would be too long, it was shortened to contain the URLs only.] Modified: trunk/reactos/dll/win32/wbemprox/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/wbemprox/CMakeLi…
Modified: trunk/reactos/dll/win32/wbemprox/builtin.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/wbemprox/builtin…
Modified: trunk/reactos/dll/win32/wbemprox/class.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/wbemprox/class.c…
Modified: trunk/reactos/dll/win32/wbemprox/main.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/wbemprox/main.c?…
Modified: trunk/reactos/dll/win32/wbemprox/process.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/wbemprox/process…
Modified: trunk/reactos/dll/win32/wbemprox/query.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/wbemprox/query.c…
Modified: trunk/reactos/dll/win32/wbemprox/reg.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/wbemprox/reg.c?r…
Modified: trunk/reactos/dll/win32/wbemprox/services.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/wbemprox/service…
Modified: trunk/reactos/dll/win32/wbemprox/table.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/wbemprox/table.c…
Modified: trunk/reactos/dll/win32/wbemprox/wbemlocator.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/wbemprox/wbemloc…
Modified: trunk/reactos/dll/win32/wbemprox/wbemprox_private.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/wbemprox/wbempro…
Modified: trunk/reactos/dll/win32/wbemprox/wql.tab.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/wbemprox/wql.tab…
Modified: trunk/reactos/dll/win32/wbemprox/wql.y URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/wbemprox/wql.y?r…
Modified: trunk/reactos/media/doc/README.WINE URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/media/doc/README.WINE?rev=…
11 years, 2 months
1
0
0
0
[akhaldi] 60421: [VBSCRIPT_WINETEST] * Sync with Wine 1.7.1. CORE-7469
by akhaldi@svn.reactos.org
Author: akhaldi Date: Sat Sep 28 15:13:32 2013 New Revision: 60421 URL:
http://svn.reactos.org/svn/reactos?rev=60421&view=rev
Log: [VBSCRIPT_WINETEST] * Sync with Wine 1.7.1. CORE-7469 Modified: trunk/rostests/winetests/vbscript/CMakeLists.txt trunk/rostests/winetests/vbscript/api.vbs trunk/rostests/winetests/vbscript/vbscript.c Modified: trunk/rostests/winetests/vbscript/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/vbscript/CMakeL…
============================================================================== --- trunk/rostests/winetests/vbscript/CMakeLists.txt [iso-8859-1] (original) +++ trunk/rostests/winetests/vbscript/CMakeLists.txt [iso-8859-1] Sat Sep 28 15:13:32 2013 @@ -1,13 +1,11 @@ -add_definitions(-D__ROS_LONG64__) add_idl_headers(vbscript_wine_test_idlheader vbsregexp55.idl) list(APPEND SOURCE createobj.c run.c vbscript.c - testlist.c - rsrc.rc) + testlist.c) list(APPEND vbscript_winetest_rc_deps ${CMAKE_CURRENT_SOURCE_DIR}/api.vbs @@ -15,10 +13,8 @@ ${CMAKE_CURRENT_SOURCE_DIR}/regexp.vbs) set_source_files_properties(rsrc.rc PROPERTIES OBJECT_DEPENDS "${vbscript_winetest_rc_deps}") - -add_executable(vbscript_winetest ${SOURCE}) -target_link_libraries(vbscript_winetest wine) +add_executable(vbscript_winetest ${SOURCE} rsrc.rc) set_module_type(vbscript_winetest win32cui) -add_importlibs(vbscript_winetest ole32 oleaut32 advapi32 msvcrt kernel32 ntdll) +add_importlibs(vbscript_winetest ole32 oleaut32 advapi32 msvcrt kernel32) add_dependencies(vbscript_winetest vbscript_wine_test_idlheader) add_cd_file(TARGET vbscript_winetest DESTINATION reactos/bin FOR all) Modified: trunk/rostests/winetests/vbscript/api.vbs URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/vbscript/api.vb…
============================================================================== --- trunk/rostests/winetests/vbscript/api.vbs [iso-8859-1] (original) +++ trunk/rostests/winetests/vbscript/api.vbs [iso-8859-1] Sat Sep 28 15:13:32 2013 @@ -134,6 +134,8 @@ Call ok(getVT(Chr(255)) = "VT_BSTR", "getVT(Chr(255)) = " & getVT(Chr(255))) Call ok(Chr(120) = "x", "Chr(120) = " & Chr(120)) Call ok(Chr(0) <> "", "Chr(0) = """"") +Call ok(Chr(120.5) = "x", "Chr(120.5) = " & Chr(120.5)) +Call ok(Chr(119.5) = "x", "Chr(119.5) = " & Chr(119.5)) Call ok(isObject(new EmptyClass), "isObject(new EmptyClass) is not true?") Set x = new EmptyClass @@ -292,6 +294,9 @@ Call ok(Space(5.2) = " ", "Space(5.2) = " & Space(5.2) & """") Call ok(Space(5.8) = " ", "Space(5.8) = " & Space(5.8) & """") Call ok(Space(5.5) = " ", "Space(5.5) = " & Space(5.5) & """") +Call ok(Space(4.5) = " ", "Space(4.5) = " & Space(4.5) & """") +Call ok(Space(0.5) = "", "Space(0.5) = " & Space(0.5) & """") +Call ok(Space(1.5) = " ", "Space(1.5) = " & Space(1.5) & """") Sub TestStrReverse(str, ex) Call ok(StrReverse(str) = ex, "StrReverse(" & str & ") = " & StrReverse(str)) @@ -310,6 +315,8 @@ TestLeft "test", 5, "test" TestLeft "test", 0, "" TestLeft 123, 2, "12" +TestLeft "123456", 1.5, "12" +TestLeft "123456", 2.5, "12" if isEnglishLang then TestLeft true, 2, "Tr" Sub TestRight(str, len, ex) @@ -383,6 +390,8 @@ Call ok(WeekDayName(1, 10) = "Sun", "WeekDayName(1, 10) = " & WeekDayName(1, 10)) Call ok(WeekDayName(1, true, 0) = "Sun", "WeekDayName(1, true, 0) = " & WeekDayName(1, true, 0)) Call ok(WeekDayName(1, true, 2) = "Mon", "WeekDayName(1, true, 2) = " & WeekDayName(1, true, 2)) + Call ok(WeekDayName(1, true, 2.5) = "Mon", "WeekDayName(1, true, 2.5) = " & WeekDayName(1, true, 2.5)) + Call ok(WeekDayName(1, true, 1.5) = "Mon", "WeekDayName(1, true, 1.5) = " & WeekDayName(1, true, 1.5)) Call ok(WeekDayName(1, true, 7) = "Sat", "WeekDayName(1, true, 7) = " & WeekDayName(1, true, 7)) Call ok(WeekDayName(1, true, 7.1) = "Sat", "WeekDayName(1, true, 7.1) = " & WeekDayName(1, true, 7.1)) @@ -424,4 +433,35 @@ Call ok(vbNo = 7, "vbNo = " & vbNo) Call ok(getVT(vbNo) = "VT_I2", "getVT(vbNo) = " & getVT(vbNo)) +Call ok(CInt(-36.75) = -37, "CInt(-36.75) = " & CInt(-36.75)) +Call ok(getVT(CInt(-36.75)) = "VT_I2", "getVT(CInt(-36.75)) = " & getVT(CInt(-36.75))) +Call ok(CInt(-36.50) = -36, "CInt(-36.50) = " & CInt(-36.50)) +Call ok(getVT(CInt(-36.50)) = "VT_I2", "getVT(CInt(-36.50)) = " & getVT(CInt(-36.50))) +Call ok(CInt(-36.25) = -36, "CInt(-36.25) = " & CInt(-36.25)) +Call ok(getVT(CInt(-36.25)) = "VT_I2", "getVT(CInt(-36.25)) = " & getVT(CInt(-36.25))) +Call ok(CInt(-36) = -36, "CInt(-36) = " & CInt(-36)) +Call ok(getVT(CInt(-36)) = "VT_I2", "getVT(CInt(-36)) = " & getVT(CInt(-36))) +Call ok(CInt(0) = 0, "CInt(0) = " & CInt(0)) +Call ok(getVT(CInt(0)) = "VT_I2", "getVT(CInt(0)) = " & getVT(CInt(0))) +Call ok(CInt(0.0) = 0, "CInt(0.0) = " & CInt(0)) +Call ok(getVT(CInt(0.0)) = "VT_I2", "getVT(CInt(0.0)) = " & getVT(CInt(0.0))) +Call ok(CInt(0.5) = 0, "CInt(0.5) = " & CInt(0)) +Call ok(getVT(CInt(0.5)) = "VT_I2", "getVT(CInt(0.5)) = " & getVT(CInt(0.5))) +Call ok(CInt(36) = 36, "CInt(36) = " & CInt(36)) +Call ok(getVT(CInt(36)) = "VT_I2", "getVT(CInt(36)) = " & getVT(CInt(36))) +Call ok(CInt(36.25) = 36, "CInt(36.25) = " & CInt(36.25)) +Call ok(getVT(CInt(36.25)) = "VT_I2", "getVT(CInt(36.25)) = " & getVT(CInt(36.25))) +Call ok(CInt(36.50) = 36, "CInt(36.50) = " & CInt(36.50)) +Call ok(getVT(CInt(36.50)) = "VT_I2", "getVT(CInt(36.50)) = " & getVT(CInt(36.50))) +Call ok(CInt(36.75) = 37, "CInt(36.75) = " & CInt(36.75)) +Call ok(getVT(CInt(36.75)) = "VT_I2", "getVT(CInt(36.75)) = " & getVT(CInt(36.75))) + + +Call ok(CBool(5) = true, "CBool(5) = " & CBool(5)) +Call ok(getVT(CBool(5)) = "VT_BOOL", "getVT(CBool(5)) = " & getVT(CBool(5))) +Call ok(CBool(0) = false, "CBool(0) = " & CBool(0)) +Call ok(getVT(CBool(0)) = "VT_BOOL", "getVT(CBool(0)) = " & getVT(CBool(0))) +Call ok(CBool(-5) = true, "CBool(-5) = " & CBool(-5)) +Call ok(getVT(CBool(-5)) = "VT_BOOL", "getVT(CBool(-5)) = " & getVT(CBool(-5))) + Call reportSuccess() Modified: trunk/rostests/winetests/vbscript/vbscript.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/vbscript/vbscri…
============================================================================== --- trunk/rostests/winetests/vbscript/vbscript.c [iso-8859-1] (original) +++ trunk/rostests/winetests/vbscript/vbscript.c [iso-8859-1] Sat Sep 28 15:13:32 2013 @@ -861,6 +861,10 @@ ok(hres == S_OK, "QueryInterface(IID_IMatchCollection2) returned %x\n", hres); IDispatch_Release(disp); + hres = IMatchCollection2_QueryInterface(mc, &IID_IMatchCollection, (void**)&unk); + ok(hres == S_OK, "QueryInterface(IID_IMatchCollection) returned %x\n", hres); + IUnknown_Release(unk); + hres = IMatchCollection2_get_Count(mc, NULL); ok(hres == E_POINTER, "get_Count returned %x, expected E_POINTER\n", hres); @@ -879,6 +883,10 @@ hres = IDispatch_QueryInterface(disp, &IID_IMatch2, (void**)&match); ok(hres == S_OK, "QueryInterface(IID_IMatch2) returned %x\n", hres); IDispatch_Release(disp); + + hres = IMatch2_QueryInterface(match, &IID_IMatch, (void**)&unk); + ok(hres == S_OK, "QueryInterface(IID_IMatch) returned %x\n", hres); + IUnknown_Release(unk); hres = IMatch2_get_Value(match, NULL); ok(hres == E_POINTER, "get_Value returned %x, expected E_POINTER\n", hres);
11 years, 2 months
1
0
0
0
[akhaldi] 60420: [VBSCRIPT] * Sync with Wine 1.7.1. CORE-7469
by akhaldi@svn.reactos.org
Author: akhaldi Date: Sat Sep 28 15:12:46 2013 New Revision: 60420 URL:
http://svn.reactos.org/svn/reactos?rev=60420&view=rev
Log: [VBSCRIPT] * Sync with Wine 1.7.1. CORE-7469 Modified: trunk/reactos/dll/win32/vbscript/CMakeLists.txt trunk/reactos/dll/win32/vbscript/global.c trunk/reactos/dll/win32/vbscript/parser.tab.c trunk/reactos/dll/win32/vbscript/parser.tab.h trunk/reactos/dll/win32/vbscript/parser.y trunk/reactos/dll/win32/vbscript/regexp.c trunk/reactos/dll/win32/vbscript/vbregexp.c trunk/reactos/dll/win32/vbscript/vbscript_main.c trunk/reactos/media/doc/README.WINE Modified: trunk/reactos/dll/win32/vbscript/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/vbscript/CMakeLi…
============================================================================== --- trunk/reactos/dll/win32/vbscript/CMakeLists.txt [iso-8859-1] (original) +++ trunk/reactos/dll/win32/vbscript/CMakeLists.txt [iso-8859-1] Sat Sep 28 15:12:46 2013 @@ -17,11 +17,6 @@ vbscript_main.c ${CMAKE_CURRENT_BINARY_DIR}/vbscript.def) -add_library(vbscript SHARED ${SOURCE} vbscript.rc) -add_idl_headers(vbscript_idlheader vbscript_classes.idl vbsglobal.idl vbsregexp55.idl) - -add_typelib(vbsglobal.idl vbsregexp10.idl vbsregexp55.idl) - list(APPEND vbscript_rc_deps ${CMAKE_CURRENT_SOURCE_DIR}/vbscript_classes.rgs ${CMAKE_CURRENT_SOURCE_DIR}/vbsglobal.rgs @@ -32,9 +27,11 @@ ${CMAKE_CURRENT_BINARY_DIR}/vbsregexp55.tlb) set_source_files_properties(vbscript.rc PROPERTIES OBJECT_DEPENDS "${vbscript_rc_deps}") - -add_dependencies(vbscript vbscript_idlheader stdole2) +add_idl_headers(vbscript_idlheader vbscript_classes.idl vbsglobal.idl vbsregexp55.idl) +add_typelib(vbsglobal.idl vbsregexp10.idl vbsregexp55.idl) +add_library(vbscript SHARED ${SOURCE} vbscript.rc) set_module_type(vbscript win32dll) target_link_libraries(vbscript wine) add_importlibs(vbscript oleaut32 ole32 user32 msvcrt kernel32 ntdll) +add_dependencies(vbscript vbscript_idlheader stdole2) add_cd_file(TARGET vbscript DESTINATION reactos/system32 FOR all) Modified: trunk/reactos/dll/win32/vbscript/global.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/vbscript/global.…
============================================================================== --- trunk/reactos/dll/win32/vbscript/global.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/vbscript/global.c [iso-8859-1] Sat Sep 28 15:12:46 2013 @@ -17,7 +17,7 @@ */ #include <assert.h> -//#include <math.h> +#include <math.h> #include "vbscript.h" #include "vbscript_defs.h" @@ -29,10 +29,10 @@ WINE_DEFAULT_DEBUG_CHANNEL(vbscript); +#define round(x) (((x) < 0) ? (int)((x) - 0.5) : (int)((x) + 0.5)) + #define VB_E_CANNOT_CREATE_OBJ 0x800a01ad #define VB_E_MK_PARSE_ERROR 0x800a01b0 - -#define round(x) (((x) < 0) ? (int)((x) - 0.5) : (int)((x) + 0.5)) /* Defined as extern in urlmon.idl, but not exported by uuid.lib */ const GUID GUID_CUSTOM_CONFIRMOBJECTSAFETY = @@ -116,6 +116,16 @@ return S_OK; } +static HRESULT return_bool(VARIANT *res, int val) +{ + if(res) { + V_VT(res) = VT_BOOL; + V_BOOL(res) = val != 0 ? VARIANT_TRUE : VARIANT_FALSE; + } + + return S_OK; +} + static inline HRESULT return_double(VARIANT *res, double val) { if(res) { @@ -152,12 +162,20 @@ *ret = V_I4(v); break; case VT_R8: { - double n = round(V_R8(v)); + double n = floor(V_R8(v)+0.5); + INT32 i; + if(!is_int32(n)) { FIXME("%lf is out of int range\n", n); return E_FAIL; } - *ret = n; + + /* Round half to even */ + i = n; + if(i%2 && n-V_R8(v) == 0.5) + i--; + + *ret = i; break; } case VT_BOOL: @@ -372,8 +390,18 @@ static HRESULT Global_CInt(vbdisp_t *This, VARIANT *arg, unsigned args_cnt, VARIANT *res) { - FIXME("\n"); - return E_NOTIMPL; + int val; + HRESULT hres; + + TRACE("%s\n", debugstr_variant(arg)); + + assert(args_cnt == 1); + + hres = to_int(arg, &val); + if(FAILED(hres)) + return hres; + + return return_int(res, val); } static HRESULT Global_CLng(vbdisp_t *This, VARIANT *arg, unsigned args_cnt, VARIANT *res) @@ -384,8 +412,30 @@ static HRESULT Global_CBool(vbdisp_t *This, VARIANT *arg, unsigned args_cnt, VARIANT *res) { - FIXME("\n"); - return E_NOTIMPL; + int val; + TRACE("%s\n", debugstr_variant(arg)); + + assert(args_cnt == 1); + + switch(V_VT(arg)) { + case VT_I2: + val = V_I2(arg); + break; + case VT_I4: + val = V_I4(arg); + break; + case VT_R4: + val = V_R4(arg) > 0.0 || V_R4(arg) < 0.0; + break; + case VT_R8: + val = V_R8(arg) > 0.0 || V_R8(arg) < 0.0; + break; + default: + ERR("Not a numeric value: %s\n", debugstr_variant(arg)); + return E_FAIL; + } + + return return_bool(res, val); } static HRESULT Global_CByte(vbdisp_t *This, VARIANT *arg, unsigned args_cnt, VARIANT *res) Modified: trunk/reactos/dll/win32/vbscript/parser.tab.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/vbscript/parser.…
============================================================================== --- trunk/reactos/dll/win32/vbscript/parser.tab.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/vbscript/parser.tab.c [iso-8859-1] Sat Sep 28 15:12:46 2013 @@ -1,10 +1,8 @@ - -/* A Bison parser, made by GNU Bison 2.4.1. */ - -/* Skeleton implementation for Bison's Yacc-like parsers in C +/* A Bison parser, made by GNU Bison 2.5. */ + +/* Bison implementation for Yacc-like parsers in C - Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 - Free Software Foundation, Inc. + Copyright (C) 1984, 1989-1990, 2000-2011 Free Software Foundation, Inc. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -46,7 +44,7 @@ #define YYBISON 1 /* Bison version. */ -#define YYBISON_VERSION "2.4.1" +#define YYBISON_VERSION "2.5" /* Skeleton name. */ #define YYSKELETON_NAME "yacc.c" @@ -75,7 +73,7 @@ /* Copy the first part of user declarations. */ -/* Line 189 of yacc.c */ +/* Line 268 of yacc.c */ #line 19 "parser.y" @@ -86,10 +84,7 @@ WINE_DEFAULT_DEBUG_CHANNEL(vbscript); -#define YYLEX_PARAM ctx -#define YYPARSE_PARAM ctx - -static int parser_error(const char*); +static int parser_error(parser_ctx_t *,const char*); static void parse_complete(parser_ctx_t*,BOOL); @@ -143,8 +138,8 @@ -/* Line 189 of yacc.c */ -#line 148 "parser.tab.c" +/* Line 268 of yacc.c */ +#line 143 "parser.tab.c" /* Enabling traces. */ #ifndef YYDEBUG @@ -248,8 +243,8 @@ typedef union YYSTYPE { -/* Line 214 of yacc.c */ -#line 88 "parser.y" +/* Line 293 of yacc.c */ +#line 87 "parser.y" const WCHAR *string; statement_t *statement; @@ -269,8 +264,8 @@ -/* Line 214 of yacc.c */ -#line 274 "parser.tab.c" +/* Line 293 of yacc.c */ +#line 269 "parser.tab.c" } YYSTYPE; # define YYSTYPE_IS_TRIVIAL 1 # define yystype YYSTYPE /* obsolescent; will be withdrawn */ @@ -281,8 +276,8 @@ /* Copy the second part of user declarations. */ -/* Line 264 of yacc.c */ -#line 286 "parser.tab.c" +/* Line 343 of yacc.c */ +#line 281 "parser.tab.c" #ifdef short # undef short @@ -332,7 +327,7 @@ #define YYSIZE_MAXIMUM ((YYSIZE_T) -1) #ifndef YY_ -# if YYENABLE_NLS +# if defined YYENABLE_NLS && YYENABLE_NLS # if ENABLE_NLS # include <libintl.h> /* INFRINGES ON USER NAME SPACE */ # define YY_(msgid) dgettext ("bison-runtime", msgid) @@ -385,11 +380,11 @@ # define alloca _alloca # else # define YYSTACK_ALLOC alloca -# if ! defined _ALLOCA_H && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ +# if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) # include <stdlib.h> /* INFRINGES ON USER NAME SPACE */ -# ifndef _STDLIB_H -# define _STDLIB_H 1 +# ifndef EXIT_SUCCESS +# define EXIT_SUCCESS 0 # endif # endif # endif @@ -412,24 +407,24 @@ # ifndef YYSTACK_ALLOC_MAXIMUM # define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM # endif -# if (defined __cplusplus && ! defined _STDLIB_H \ +# if (defined __cplusplus && ! defined EXIT_SUCCESS \ && ! ((defined YYMALLOC || defined malloc) \ && (defined YYFREE || defined free))) # include <stdlib.h> /* INFRINGES ON USER NAME SPACE */ -# ifndef _STDLIB_H -# define _STDLIB_H 1 +# ifndef EXIT_SUCCESS +# define EXIT_SUCCESS 0 # endif # endif # ifndef YYMALLOC # define YYMALLOC malloc -# if ! defined malloc && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ +# if ! defined malloc && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */ # endif # endif # ifndef YYFREE # define YYFREE free -# if ! defined free && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ +# if ! defined free && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) void free (void *); /* INFRINGES ON USER NAME SPACE */ # endif @@ -458,6 +453,27 @@ ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \ + YYSTACK_GAP_MAXIMUM) +# define YYCOPY_NEEDED 1 + +/* Relocate STACK from its old location to the new one. The + local variables YYSIZE and YYSTACKSIZE give the old and new number of + elements in the stack, and YYPTR gives the new location of the + stack. Advance YYPTR to a properly aligned location for the next + stack. */ +# define YYSTACK_RELOCATE(Stack_alloc, Stack) \ + do \ + { \ + YYSIZE_T yynewbytes; \ + YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \ + Stack = &yyptr->Stack_alloc; \ + yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ + yyptr += yynewbytes / sizeof (*yyptr); \ + } \ + while (YYID (0)) + +#endif + +#if defined YYCOPY_NEEDED && YYCOPY_NEEDED /* Copy COUNT objects from FROM to TO. The source and destination do not overlap. */ # ifndef YYCOPY @@ -475,24 +491,7 @@ while (YYID (0)) # endif # endif - -/* Relocate STACK from its old location to the new one. The - local variables YYSIZE and YYSTACKSIZE give the old and new number of - elements in the stack, and YYPTR gives the new location of the - stack. Advance YYPTR to a properly aligned location for the next - stack. */ -# define YYSTACK_RELOCATE(Stack_alloc, Stack) \ - do \ - { \ - YYSIZE_T yynewbytes; \ - YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \ - Stack = &yyptr->Stack_alloc; \ - yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ - yyptr += yynewbytes / sizeof (*yyptr); \ - } \ - while (YYID (0)) - -#endif +#endif /* !YYCOPY_NEEDED */ /* YYFINAL -- State number of the termination state. */ #define YYFINAL 5 @@ -637,22 +636,22 @@ /* YYRLINE[YYN] -- source line where rule number YYN was defined. */ static const yytype_uint16 yyrline[] = { - 0, 145, 145, 148, 149, 151, 153, 154, 157, 158, - 161, 162, 165, 168, 169, 170, 171, 172, 175, 176, - 177, 179, 180, 181, 183, 186, 189, 190, 191, 192, - 193, 194, 195, 196, 198, 199, 200, 201, 202, 204, - 206, 210, 211, 214, 215, 218, 219, 222, 225, 226, - 229, 230, 233, 234, 237, 239, 240, 243, 245, 248, - 249, 252, 253, 256, 260, 261, 264, 265, 266, 270, - 271, 274, 275, 277, 279, 282, 283, 286, 287, 290, - 291, 294, 295, 298, 299, 302, 303, 306, 307, 310, - 311, 312, 313, 314, 315, 316, 317, 320, 321, 324, - 325, 326, 329, 330, 333, 334, 338, 339, 341, 345, - 346, 349, 350, 351, 352, 355, 356, 359, 360, 361, - 362, 363, 364, 365, 368, 369, 370, 371, 375, 376, - 379, 382, 383, 384, 385, 388, 390, 392, 396, 398, - 402, 403, 406, 407, 408, 411, 412, 415, 416, 419, - 420, 421, 425, 426 + 0, 144, 144, 147, 148, 150, 152, 153, 156, 157, + 160, 161, 164, 167, 168, 169, 170, 171, 174, 175, + 176, 178, 179, 180, 182, 185, 188, 189, 190, 191, + 192, 193, 194, 195, 197, 198, 199, 200, 201, 203, + 205, 209, 210, 213, 214, 217, 218, 221, 224, 225, + 228, 229, 232, 233, 236, 238, 239, 242, 244, 247, + 248, 251, 252, 255, 259, 260, 263, 264, 265, 269, + 270, 273, 274, 276, 278, 281, 282, 285, 286, 289, + 290, 293, 294, 297, 298, 301, 302, 305, 306, 309, + 310, 311, 312, 313, 314, 315, 316, 319, 320, 323, + 324, 325, 328, 329, 332, 333, 337, 338, 340, 344, + 345, 348, 349, 350, 351, 354, 355, 358, 359, 360, + 361, 362, 363, 364, 367, 368, 369, 370, 374, 375, + 378, 381, 382, 383, 384, 387, 389, 391, 395, 397, + 401, 402, 405, 406, 407, 410, 411, 414, 415, 418, + 419, 420, 424, 425 }; #endif @@ -749,8 +748,8 @@ 2, 2, 1, 1 }; -/* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state - STATE-NUM when YYTABLE doesn't specify something else to do. Zero +/* YYDEFACT[STATE-NAME] -- Default reduction number in state STATE-NUM. + Performed when YYTABLE doesn't specify something else to do. Zero means the default is an error. */ static const yytype_uint8 yydefact[] = { @@ -851,8 +850,7 @@ /* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If positive, shift that token. If negative, reduce the rule which - number is the opposite. If zero, do what YYDEFACT says. - If YYTABLE_NINF, syntax error. */ + number is the opposite. If YYTABLE_NINF, syntax error. */ #define YYTABLE_NINF -141 static const yytype_int16 yytable[] = { @@ -939,6 +937,12 @@ 28 }; +#define yypact_value_is_default(yystate) \ + ((yystate) == (-184)) + +#define yytable_value_is_error(yytable_value) \ + YYID (0) + static const yytype_int16 yycheck[] = { 6, 143, 6, 9, 27, 9, 6, 32, 148, 59, @@ -1074,9 +1078,18 @@ /* Like YYERROR except do call yyerror. This remains here temporarily to ease the transition to the new meaning of YYERROR, for GCC. - Once GCC version 2 has supplanted version 1, this can go. */ + Once GCC version 2 has supplanted version 1, this can go. However, + YYFAIL appears to be in use. Nevertheless, it is formally deprecated + in Bison 2.4.2's NEWS entry, where a plan to phase it out is + discussed. */ #define YYFAIL goto yyerrlab +#if defined YYFAIL + /* This is here to suppress warnings from the GCC cpp's + -Wunused-macros. Normally we don't worry about that warning, but + some users do, and we want to make it easy for users to remove + YYFAIL uses, which will produce warnings from Bison 2.5. */ +#endif #define YYRECOVERING() (!!yyerrstatus) @@ -1086,13 +1099,12 @@ { \ yychar = (Token); \ yylval = (Value); \ - yytoken = YYTRANSLATE (yychar); \ YYPOPSTACK (1); \ goto yybackup; \ } \ else \ { \ - yyerror (YY_("syntax error: cannot back up")); \ + yyerror (ctx, YY_("syntax error: cannot back up")); \ YYERROR; \ } \ while (YYID (0)) @@ -1128,19 +1140,10 @@ #endif -/* YY_LOCATION_PRINT -- Print the location on the stream. - This macro was not mandated originally: define only if we know - we won't break user code: when these are the locations we know. */ +/* This macro is provided for backward compatibility. */ #ifndef YY_LOCATION_PRINT -# if YYLTYPE_IS_TRIVIAL -# define YY_LOCATION_PRINT(File, Loc) \ - fprintf (File, "%d.%d-%d.%d", \ - (Loc).first_line, (Loc).first_column, \ - (Loc).last_line, (Loc).last_column) -# else -# define YY_LOCATION_PRINT(File, Loc) ((void) 0) -# endif +# define YY_LOCATION_PRINT(File, Loc) ((void) 0) #endif @@ -1149,7 +1152,7 @@ #ifdef YYLEX_PARAM # define YYLEX yylex (&yylval, YYLEX_PARAM) #else -# define YYLEX yylex (&yylval) +# define YYLEX yylex (&yylval, ctx) #endif /* Enable debugging if requested. */ @@ -1172,7 +1175,7 @@ { \ YYFPRINTF (stderr, "%s ", Title); \ yy_symbol_print (stderr, \ - Type, Value); \ + Type, Value, ctx); \ YYFPRINTF (stderr, "\n"); \ } \ } while (YYID (0)) @@ -1186,17 +1189,19 @@ #if (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) static void -yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep) +yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, parser_ctx_t *ctx) #else static void -yy_symbol_value_print (yyoutput, yytype, yyvaluep) +yy_symbol_value_print (yyoutput, yytype, yyvaluep, ctx) FILE *yyoutput; int yytype; YYSTYPE const * const yyvaluep; + parser_ctx_t *ctx; #endif { if (!yyvaluep) return; + YYUSE (ctx); # ifdef YYPRINT if (yytype < YYNTOKENS) YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep); @@ -1218,13 +1223,14 @@ #if (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) static void -yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep) +yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, parser_ctx_t *ctx) #else static void -yy_symbol_print (yyoutput, yytype, yyvaluep) +yy_symbol_print (yyoutput, yytype, yyvaluep, ctx) FILE *yyoutput; int yytype; YYSTYPE const * const yyvaluep; + parser_ctx_t *ctx; #endif { if (yytype < YYNTOKENS) @@ -1232,7 +1238,7 @@ else YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]); - yy_symbol_value_print (yyoutput, yytype, yyvaluep); + yy_symbol_value_print (yyoutput, yytype, yyvaluep, ctx); YYFPRINTF (yyoutput, ")"); } @@ -1275,12 +1281,13 @@ #if (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) static void -yy_reduce_print (YYSTYPE *yyvsp, int yyrule) +yy_reduce_print (YYSTYPE *yyvsp, int yyrule, parser_ctx_t *ctx) #else static void -yy_reduce_print (yyvsp, yyrule) +yy_reduce_print (yyvsp, yyrule, ctx) YYSTYPE *yyvsp; int yyrule; + parser_ctx_t *ctx; #endif { int yynrhs = yyr2[yyrule]; @@ -1294,7 +1301,7 @@ YYFPRINTF (stderr, " $%d = ", yyi + 1); yy_symbol_print (stderr, yyrhs[yyprhs[yyrule] + yyi], &(yyvsp[(yyi + 1) - (yynrhs)]) - ); + , ctx); YYFPRINTF (stderr, "\n"); } } @@ -1302,7 +1309,7 @@ # define YY_REDUCE_PRINT(Rule) \ do { \ if (yydebug) \ - yy_reduce_print (yyvsp, Rule); \ + yy_reduce_print (yyvsp, Rule, ctx); \ } while (YYID (0)) /* Nonzero means print parse trace. It is left uninitialized so that @@ -1332,7 +1339,6 @@ # define YYMAXDEPTH 10000 #endif - #if YYERROR_VERBOSE @@ -1435,115 +1441,142 @@ } # endif -/* Copy into YYRESULT an error message about the unexpected token - YYCHAR while in state YYSTATE. Return the number of bytes copied, - including the terminating null byte. If YYRESULT is null, do not - copy anything; just return the number of bytes that would be - copied. As a special case, return 0 if an ordinary "syntax error" - message will do. Return YYSIZE_MAXIMUM if overflow occurs during - size calculation. */ -static YYSIZE_T -yysyntax_error (char *yyresult, int yystate, int yychar) -{ - int yyn = yypact[yystate]; - - if (! (YYPACT_NINF < yyn && yyn <= YYLAST)) - return 0; - else +/* Copy into *YYMSG, which is of size *YYMSG_ALLOC, an error message + about the unexpected token YYTOKEN for the state stack whose top is + YYSSP. + + Return 0 if *YYMSG was successfully written. Return 1 if *YYMSG is + not large enough to hold the message. In that case, also set + *YYMSG_ALLOC to the required number of bytes. Return 2 if the + required number of bytes is too large to store. */ +static int +yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg, + yytype_int16 *yyssp, int yytoken) +{ + YYSIZE_T yysize0 = yytnamerr (0, yytname[yytoken]); + YYSIZE_T yysize = yysize0; + YYSIZE_T yysize1; + enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; + /* Internationalized format string. */ + const char *yyformat = 0; + /* Arguments of yyformat. */ + char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; + /* Number of reported tokens (one for the "unexpected", one per + "expected"). */ + int yycount = 0; + + /* There are many possibilities here to consider: + - Assume YYFAIL is not used. It's too flawed to consider. See + <
http://lists.gnu.org/archive/html/bison-patches/2009-12/msg00024.html
> + for details. YYERROR is fine as it does not invoke this + function. + - If this state is a consistent state with a default action, then + the only way this function was invoked is if the default action + is an error action. In that case, don't check for expected + tokens because there are none. + - The only way there can be no lookahead present (in yychar) is if + this state is a consistent state with a default action. Thus, + detecting the absence of a lookahead is sufficient to determine + that there is no unexpected or expected token to report. In that + case, just report a simple "syntax error". + - Don't assume there isn't a lookahead just because this state is a + consistent state with a default action. There might have been a + previous inconsistent state, consistent state with a non-default + action, or user semantic action that manipulated yychar. + - Of course, the expected token list depends on states to have + correct lookahead information, and it depends on the parser not + to perform extra reductions after fetching a lookahead from the + scanner and before detecting a syntax error. Thus, state merging + (from LALR or IELR) and default reductions corrupt the expected + token list. However, the list is correct for canonical LR with + one exception: it will still contain any token that will not be + accepted due to an error action in a later state. + */ + if (yytoken != YYEMPTY) { - int yytype = YYTRANSLATE (yychar); - YYSIZE_T yysize0 = yytnamerr (0, yytname[yytype]); - YYSIZE_T yysize = yysize0; - YYSIZE_T yysize1; - int yysize_overflow = 0; - enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; - char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; - int yyx; - -# if 0 - /* This is so xgettext sees the translatable formats that are - constructed on the fly. */ - YY_("syntax error, unexpected %s"); - YY_("syntax error, unexpected %s, expecting %s"); - YY_("syntax error, unexpected %s, expecting %s or %s"); - YY_("syntax error, unexpected %s, expecting %s or %s or %s"); - YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"); -# endif - char *yyfmt; - char const *yyf; - static char const yyunexpected[] = "syntax error, unexpected %s"; - static char const yyexpecting[] = ", expecting %s"; - static char const yyor[] = " or %s"; - char yyformat[sizeof yyunexpected - + sizeof yyexpecting - 1 - + ((YYERROR_VERBOSE_ARGS_MAXIMUM - 2) - * (sizeof yyor - 1))]; - char const *yyprefix = yyexpecting; - - /* Start YYX at -YYN if negative to avoid negative indexes in - YYCHECK. */ - int yyxbegin = yyn < 0 ? -yyn : 0; - - /* Stay within bounds of both yycheck and yytname. */ - int yychecklim = YYLAST - yyn + 1; - int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS; - int yycount = 1; - - yyarg[0] = yytname[yytype]; - yyfmt = yystpcpy (yyformat, yyunexpected); - - for (yyx = yyxbegin; yyx < yyxend; ++yyx) - if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR) - { - if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM) - { - yycount = 1; - yysize = yysize0; - yyformat[sizeof yyunexpected - 1] = '\0'; - break; - } - yyarg[yycount++] = yytname[yyx]; - yysize1 = yysize + yytnamerr (0, yytname[yyx]); - yysize_overflow |= (yysize1 < yysize); - yysize = yysize1; - yyfmt = yystpcpy (yyfmt, yyprefix); - yyprefix = yyor; - } - - yyf = YY_(yyformat); - yysize1 = yysize + yystrlen (yyf); - yysize_overflow |= (yysize1 < yysize); - yysize = yysize1; - - if (yysize_overflow) - return YYSIZE_MAXIMUM; - - if (yyresult) - { - /* Avoid sprintf, as that infringes on the user's name space. - Don't have undefined behavior even if the translation - produced a string with the wrong number of "%s"s. */ - char *yyp = yyresult; - int yyi = 0; - while ((*yyp = *yyf) != '\0') - { - if (*yyp == '%' && yyf[1] == 's' && yyi < yycount) - { - yyp += yytnamerr (yyp, yyarg[yyi++]); - yyf += 2; - } - else - { - yyp++; - yyf++; - } - } - } - return yysize; + int yyn = yypact[*yyssp]; + yyarg[yycount++] = yytname[yytoken]; + if (!yypact_value_is_default (yyn)) + { + /* Start YYX at -YYN if negative to avoid negative indexes in + YYCHECK. In other words, skip the first -YYN actions for + this state because they are default actions. */ + int yyxbegin = yyn < 0 ? -yyn : 0; + /* Stay within bounds of both yycheck and yytname. */ + int yychecklim = YYLAST - yyn + 1; + int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS; + int yyx; + + for (yyx = yyxbegin; yyx < yyxend; ++yyx) + if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR + && !yytable_value_is_error (yytable[yyx + yyn])) + { + if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM) + { + yycount = 1; + yysize = yysize0; + break; + } + yyarg[yycount++] = yytname[yyx]; + yysize1 = yysize + yytnamerr (0, yytname[yyx]); + if (! (yysize <= yysize1 + && yysize1 <= YYSTACK_ALLOC_MAXIMUM)) + return 2; + yysize = yysize1; + } + } } + + switch (yycount) + { +# define YYCASE_(N, S) \ + case N: \ + yyformat = S; \ + break + YYCASE_(0, YY_("syntax error")); + YYCASE_(1, YY_("syntax error, unexpected %s")); + YYCASE_(2, YY_("syntax error, unexpected %s, expecting %s")); + YYCASE_(3, YY_("syntax error, unexpected %s, expecting %s or %s")); + YYCASE_(4, YY_("syntax error, unexpected %s, expecting %s or %s or %s")); + YYCASE_(5, YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s")); +# undef YYCASE_ + } + + yysize1 = yysize + yystrlen (yyformat); + if (! (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)) + return 2; + yysize = yysize1; + + if (*yymsg_alloc < yysize) + { + *yymsg_alloc = 2 * yysize; + if (! (yysize <= *yymsg_alloc + && *yymsg_alloc <= YYSTACK_ALLOC_MAXIMUM)) + *yymsg_alloc = YYSTACK_ALLOC_MAXIMUM; + return 1; + } + + /* Avoid sprintf, as that infringes on the user's name space. + Don't have undefined behavior even if the translation + produced a string with the wrong number of "%s"s. */ + { + char *yyp = *yymsg; + int yyi = 0; + while ((*yyp = *yyformat) != '\0') + if (*yyp == '%' && yyformat[1] == 's' && yyi < yycount) + { + yyp += yytnamerr (yyp, yyarg[yyi++]); + yyformat += 2; + } + else + { + yyp++; + yyformat++; + } + } + return 0; } #endif /* YYERROR_VERBOSE */ - /*-----------------------------------------------. | Release the memory associated to this symbol. | @@ -1553,16 +1586,18 @@ #if (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) static void -yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep) +yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep, parser_ctx_t *ctx) #else static void -yydestruct (yymsg, yytype, yyvaluep) +yydestruct (yymsg, yytype, yyvaluep, ctx) const char *yymsg; int yytype; YYSTYPE *yyvaluep; + parser_ctx_t *ctx; #endif { YYUSE (yyvaluep); + YYUSE (ctx); if (!yymsg) yymsg = "Deleting"; @@ -1575,6 +1610,7 @@ break; } } + /* Prevent warnings from -Wmissing-prototypes. */ #ifdef YYPARSE_PARAM @@ -1585,19 +1621,16 @@ #endif #else /* ! YYPARSE_PARAM */ #if defined __STDC__ || defined __cplusplus -int yyparse (void); +int yyparse (parser_ctx_t *ctx); #else int yyparse (); #endif #endif /* ! YYPARSE_PARAM */ - - - -/*-------------------------. -| yyparse or yypush_parse. | -`-------------------------*/ +/*----------. +| yyparse. | +`----------*/ #ifdef YYPARSE_PARAM #if (defined __STDC__ || defined __C99__FUNC__ \ @@ -1613,11 +1646,11 @@ #if (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) int -yyparse (void) +yyparse (parser_ctx_t *ctx) #else int -yyparse () - +yyparse (ctx) + parser_ctx_t *ctx; #endif #endif { @@ -1784,7 +1817,7 @@ /* First try to decide what to do without reference to lookahead token. */ yyn = yypact[yystate]; - if (yyn == YYPACT_NINF) + if (yypact_value_is_default (yyn)) goto yydefault; /* Not known => get a lookahead token if don't already have one. */ @@ -1815,8 +1848,8 @@ yyn = yytable[yyn]; if (yyn <= 0) { - if (yyn == 0 || yyn == YYTABLE_NINF) - goto yyerrlab; + if (yytable_value_is_error (yyn)) + goto yyerrlab; yyn = -yyn; goto yyreduce; } @@ -1871,1041 +1904,1052 @@ { case 2: -/* Line 1455 of yacc.c */ -#line 145 "parser.y" - { parse_complete(ctx, (yyvsp[(1) - (3)].bool)); ;} +/* Line 1806 of yacc.c */ +#line 144 "parser.y" + { parse_complete(ctx, (yyvsp[(1) - (3)].bool)); } break; case 3: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 147 "parser.y" + { (yyval.bool) = FALSE; } + break; + + case 4: + +/* Line 1806 of yacc.c */ #line 148 "parser.y" - { (yyval.bool) = FALSE; ;} - break; - - case 4: - -/* Line 1455 of yacc.c */ -#line 149 "parser.y" - { (yyval.bool) = TRUE; ;} + { (yyval.bool) = TRUE; } break; case 6: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 152 "parser.y" + { source_add_statement(ctx, (yyvsp[(2) - (2)].statement)); } + break; + + case 7: + +/* Line 1806 of yacc.c */ #line 153 "parser.y" - { source_add_statement(ctx, (yyvsp[(2) - (2)].statement)); ;} - break; - - case 7: - -/* Line 1455 of yacc.c */ -#line 154 "parser.y" - { source_add_class(ctx, (yyvsp[(2) - (2)].class_decl)); ;} + { source_add_class(ctx, (yyvsp[(2) - (2)].class_decl)); } break; case 8: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 156 "parser.y" + { (yyval.statement) = NULL; } + break; + + case 9: + +/* Line 1806 of yacc.c */ #line 157 "parser.y" - { (yyval.statement) = NULL; ;} - break; - - case 9: - -/* Line 1455 of yacc.c */ -#line 158 "parser.y" - { (yyval.statement) = (yyvsp[(1) - (1)].statement); ;} + { (yyval.statement) = (yyvsp[(1) - (1)].statement); } break; case 10: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 160 "parser.y" + { (yyval.statement) = (yyvsp[(1) - (1)].statement); } + break; + + case 11: + +/* Line 1806 of yacc.c */ #line 161 "parser.y" - { (yyval.statement) = (yyvsp[(1) - (1)].statement); ;} - break; - - case 11: - -/* Line 1455 of yacc.c */ -#line 162 "parser.y" - { (yyval.statement) = link_statements((yyvsp[(1) - (2)].statement), (yyvsp[(2) - (2)].statement)); ;} + { (yyval.statement) = link_statements((yyvsp[(1) - (2)].statement), (yyvsp[(2) - (2)].statement)); } break; case 12: -/* Line 1455 of yacc.c */ -#line 165 "parser.y" - { (yyval.statement) = (yyvsp[(1) - (2)].statement); ;} +/* Line 1806 of yacc.c */ +#line 164 "parser.y" + { (yyval.statement) = (yyvsp[(1) - (2)].statement); } break; case 13: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 167 "parser.y" + { (yyval.statement) = NULL; } + break; + + case 14: + +/* Line 1806 of yacc.c */ #line 168 "parser.y" - { (yyval.statement) = NULL; ;} - break; - - case 14: - -/* Line 1455 of yacc.c */ + { (yyval.statement) = (yyvsp[(2) - (2)].statement); } + break; + + case 15: + +/* Line 1806 of yacc.c */ #line 169 "parser.y" - { (yyval.statement) = (yyvsp[(2) - (2)].statement); ;} - break; - - case 15: - -/* Line 1455 of yacc.c */ + { (yyval.statement) = (yyvsp[(1) - (1)].statement); } + break; + + case 16: + +/* Line 1806 of yacc.c */ #line 170 "parser.y" - { (yyval.statement) = (yyvsp[(1) - (1)].statement); ;} - break; - - case 16: - -/* Line 1455 of yacc.c */ + { (yyvsp[(1) - (3)].statement)->next = (yyvsp[(3) - (3)].statement); (yyval.statement) = (yyvsp[(1) - (3)].statement); } + break; + + case 17: + +/* Line 1806 of yacc.c */ #line 171 "parser.y" - { (yyvsp[(1) - (3)].statement)->next = (yyvsp[(3) - (3)].statement); (yyval.statement) = (yyvsp[(1) - (3)].statement); ;} - break; - - case 17: - -/* Line 1455 of yacc.c */ -#line 172 "parser.y" - { (yyval.statement) = (yyvsp[(1) - (2)].statement); ;} + { (yyval.statement) = (yyvsp[(1) - (2)].statement); } break; case 18: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 174 "parser.y" + { (yyvsp[(1) - (2)].member)->args = (yyvsp[(2) - (2)].expression); (yyval.statement) = new_call_statement(ctx, FALSE, (yyvsp[(1) - (2)].member)); CHECK_ERROR; } + break; + + case 19: + +/* Line 1806 of yacc.c */ #line 175 "parser.y" - { (yyvsp[(1) - (2)].member)->args = (yyvsp[(2) - (2)].expression); (yyval.statement) = new_call_statement(ctx, FALSE, (yyvsp[(1) - (2)].member)); CHECK_ERROR; ;} - break; - - case 19: - -/* Line 1455 of yacc.c */ -#line 176 "parser.y" - { (yyvsp[(2) - (3)].member)->args = (yyvsp[(3) - (3)].expression); (yyval.statement) = new_call_statement(ctx, TRUE, (yyvsp[(2) - (3)].member)); CHECK_ERROR; ;} + { (yyvsp[(2) - (3)].member)->args = (yyvsp[(3) - (3)].expression); (yyval.statement) = new_call_statement(ctx, TRUE, (yyvsp[(2) - (3)].member)); CHECK_ERROR; } break; case 20: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 177 "parser.y" + { (yyvsp[(1) - (4)].member)->args = (yyvsp[(2) - (4)].expression); (yyval.statement) = new_assign_statement(ctx, (yyvsp[(1) - (4)].member), (yyvsp[(4) - (4)].expression)); CHECK_ERROR; } + break; + + case 21: + +/* Line 1806 of yacc.c */ #line 178 "parser.y" - { (yyvsp[(1) - (4)].member)->args = (yyvsp[(2) - (4)].expression); (yyval.statement) = new_assign_statement(ctx, (yyvsp[(1) - (4)].member), (yyvsp[(4) - (4)].expression)); CHECK_ERROR; ;} - break; - - case 21: - -/* Line 1455 of yacc.c */ + { (yyval.statement) = new_dim_statement(ctx, (yyvsp[(2) - (2)].dim_decl)); CHECK_ERROR; } + break; + + case 22: + +/* Line 1806 of yacc.c */ #line 179 "parser.y" - { (yyval.statement) = new_dim_statement(ctx, (yyvsp[(2) - (2)].dim_decl)); CHECK_ERROR; ;} - break; - - case 22: - -/* Line 1455 of yacc.c */ -#line 180 "parser.y" - { (yyval.statement) = (yyvsp[(1) - (1)].statement); ;} + { (yyval.statement) = (yyvsp[(1) - (1)].statement); } break; case 23: -/* Line 1455 of yacc.c */ -#line 182 "parser.y" - { (yyval.statement) = new_while_statement(ctx, STAT_WHILE, (yyvsp[(2) - (5)].expression), (yyvsp[(4) - (5)].statement)); CHECK_ERROR; ;} +/* Line 1806 of yacc.c */ +#line 181 "parser.y" + { (yyval.statement) = new_while_statement(ctx, STAT_WHILE, (yyvsp[(2) - (5)].expression), (yyvsp[(4) - (5)].statement)); CHECK_ERROR; } break; case 24: -/* Line 1455 of yacc.c */ -#line 184 "parser.y" +/* Line 1806 of yacc.c */ +#line 183 "parser.y" { (yyval.statement) = new_while_statement(ctx, (yyvsp[(2) - (6)].bool) ? STAT_WHILELOOP : STAT_UNTIL, (yyvsp[(3) - (6)].expression), (yyvsp[(5) - (6)].statement)); - CHECK_ERROR; ;} + CHECK_ERROR; } break; case 25: -/* Line 1455 of yacc.c */ -#line 187 "parser.y" +/* Line 1806 of yacc.c */ +#line 186 "parser.y" { (yyval.statement) = new_while_statement(ctx, (yyvsp[(5) - (6)].bool) ? STAT_DOWHILE : STAT_DOUNTIL, (yyvsp[(6) - (6)].expression), (yyvsp[(3) - (6)].statement)); - CHECK_ERROR; ;} + CHECK_ERROR; } break; case 26: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 188 "parser.y" + { (yyval.statement) = new_while_statement(ctx, STAT_DOWHILE, NULL, (yyvsp[(3) - (4)].statement)); CHECK_ERROR; } + break; + + case 27: + +/* Line 1806 of yacc.c */ #line 189 "parser.y" - { (yyval.statement) = new_while_statement(ctx, STAT_DOWHILE, NULL, (yyvsp[(3) - (4)].statement)); CHECK_ERROR; ;} - break; - - case 27: - -/* Line 1455 of yacc.c */ + { (yyval.statement) = new_function_statement(ctx, (yyvsp[(1) - (1)].func_decl)); CHECK_ERROR; } + break; + + case 28: + +/* Line 1806 of yacc.c */ #line 190 "parser.y" - { (yyval.statement) = new_function_statement(ctx, (yyvsp[(1) - (1)].func_decl)); CHECK_ERROR; ;} - break; - - case 28: - -/* Line 1455 of yacc.c */ + { (yyval.statement) = new_statement(ctx, STAT_EXITDO, 0); CHECK_ERROR; } + break; + + case 29: + +/* Line 1806 of yacc.c */ #line 191 "parser.y" - { (yyval.statement) = new_statement(ctx, STAT_EXITDO, 0); CHECK_ERROR; ;} - break; - - case 29: - -/* Line 1455 of yacc.c */ + { (yyval.statement) = new_statement(ctx, STAT_EXITFOR, 0); CHECK_ERROR; } + break; + + case 30: + +/* Line 1806 of yacc.c */ #line 192 "parser.y" - { (yyval.statement) = new_statement(ctx, STAT_EXITFOR, 0); CHECK_ERROR; ;} - break; - - case 30: - -/* Line 1455 of yacc.c */ + { (yyval.statement) = new_statement(ctx, STAT_EXITFUNC, 0); CHECK_ERROR; } + break; + + case 31: + +/* Line 1806 of yacc.c */ #line 193 "parser.y" - { (yyval.statement) = new_statement(ctx, STAT_EXITFUNC, 0); CHECK_ERROR; ;} - break; - - case 31: - -/* Line 1455 of yacc.c */ + { (yyval.statement) = new_statement(ctx, STAT_EXITPROP, 0); CHECK_ERROR; } + break; + + case 32: + +/* Line 1806 of yacc.c */ #line 194 "parser.y" - { (yyval.statement) = new_statement(ctx, STAT_EXITPROP, 0); CHECK_ERROR; ;} - break; - - case 32: - -/* Line 1455 of yacc.c */ -#line 195 "parser.y" - { (yyval.statement) = new_statement(ctx, STAT_EXITSUB, 0); CHECK_ERROR; ;} + { (yyval.statement) = new_statement(ctx, STAT_EXITSUB, 0); CHECK_ERROR; } break; case 33: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 196 "parser.y" + { (yyvsp[(2) - (5)].member)->args = (yyvsp[(3) - (5)].expression); (yyval.statement) = new_set_statement(ctx, (yyvsp[(2) - (5)].member), (yyvsp[(5) - (5)].expression)); CHECK_ERROR; } + break; + + case 34: + +/* Line 1806 of yacc.c */ #line 197 "parser.y" - { (yyvsp[(2) - (5)].member)->args = (yyvsp[(3) - (5)].expression); (yyval.statement) = new_set_statement(ctx, (yyvsp[(2) - (5)].member), (yyvsp[(5) - (5)].expression)); CHECK_ERROR; ;} - break; - - case 34: - -/* Line 1455 of yacc.c */ + { (yyval.statement) = new_statement(ctx, STAT_STOP, 0); CHECK_ERROR; } + break; + + case 35: + +/* Line 1806 of yacc.c */ #line 198 "parser.y" - { (yyval.statement) = new_statement(ctx, STAT_STOP, 0); CHECK_ERROR; ;} - break; - - case 35: - -/* Line 1455 of yacc.c */ + { (yyval.statement) = new_onerror_statement(ctx, TRUE); CHECK_ERROR; } + break; + + case 36: + +/* Line 1806 of yacc.c */ #line 199 "parser.y" - { (yyval.statement) = new_onerror_statement(ctx, TRUE); CHECK_ERROR; ;} - break; - - case 36: - -/* Line 1455 of yacc.c */ + { (yyval.statement) = new_onerror_statement(ctx, FALSE); CHECK_ERROR; } + break; + + case 37: + +/* Line 1806 of yacc.c */ #line 200 "parser.y" - { (yyval.statement) = new_onerror_statement(ctx, FALSE); CHECK_ERROR; ;} - break; - - case 37: - -/* Line 1455 of yacc.c */ -#line 201 "parser.y" - { (yyval.statement) = new_const_statement(ctx, (yyvsp[(2) - (2)].const_decl)); CHECK_ERROR; ;} + { (yyval.statement) = new_const_statement(ctx, (yyvsp[(2) - (2)].const_decl)); CHECK_ERROR; } break; case 38: -/* Line 1455 of yacc.c */ -#line 203 "parser.y" - { (yyval.statement) = new_forto_statement(ctx, (yyvsp[(2) - (10)].string), (yyvsp[(4) - (10)].expression), (yyvsp[(6) - (10)].expression), (yyvsp[(7) - (10)].expression), (yyvsp[(9) - (10)].statement)); CHECK_ERROR; ;} +/* Line 1806 of yacc.c */ +#line 202 "parser.y" + { (yyval.statement) = new_forto_statement(ctx, (yyvsp[(2) - (10)].string), (yyvsp[(4) - (10)].expression), (yyvsp[(6) - (10)].expression), (yyvsp[(7) - (10)].expression), (yyvsp[(9) - (10)].statement)); CHECK_ERROR; } break; case 39: -/* Line 1455 of yacc.c */ -#line 205 "parser.y" - { (yyval.statement) = new_foreach_statement(ctx, (yyvsp[(3) - (8)].string), (yyvsp[(5) - (8)].expression), (yyvsp[(7) - (8)].statement)); ;} +/* Line 1806 of yacc.c */ +#line 204 "parser.y" + { (yyval.statement) = new_foreach_statement(ctx, (yyvsp[(3) - (8)].string), (yyvsp[(5) - (8)].expression), (yyvsp[(7) - (8)].statement)); } break; case 40: -/* Line 1455 of yacc.c */ -#line 207 "parser.y" - { (yyval.statement) = new_select_statement(ctx, (yyvsp[(3) - (7)].expression), (yyvsp[(5) - (7)].case_clausule)); ;} +/* Line 1806 of yacc.c */ +#line 206 "parser.y" + { (yyval.statement) = new_select_statement(ctx, (yyvsp[(3) - (7)].expression), (yyvsp[(5) - (7)].case_clausule)); } break; case 41: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 209 "parser.y" + { (yyval.member) = new_member_expression(ctx, NULL, (yyvsp[(1) - (1)].string)); CHECK_ERROR; } + break; + + case 42: + +/* Line 1806 of yacc.c */ #line 210 "parser.y" - { (yyval.member) = new_member_expression(ctx, NULL, (yyvsp[(1) - (1)].string)); CHECK_ERROR; ;} - break; - - case 42: - -/* Line 1455 of yacc.c */ -#line 211 "parser.y" - { (yyval.member) = new_member_expression(ctx, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].string)); CHECK_ERROR; ;} + { (yyval.member) = new_member_expression(ctx, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].string)); CHECK_ERROR; } break; case 43: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 213 "parser.y" + { (yyval.dim_decl) = new_dim_decl(ctx, (yyvsp[(1) - (1)].string), NULL); CHECK_ERROR; } + break; + + case 44: + +/* Line 1806 of yacc.c */ #line 214 "parser.y" - { (yyval.dim_decl) = new_dim_decl(ctx, (yyvsp[(1) - (1)].string), NULL); CHECK_ERROR; ;} - break; - - case 44: - -/* Line 1455 of yacc.c */ -#line 215 "parser.y" - { (yyval.dim_decl) = new_dim_decl(ctx, (yyvsp[(1) - (3)].string), (yyvsp[(3) - (3)].dim_decl)); CHECK_ERROR; ;} + { (yyval.dim_decl) = new_dim_decl(ctx, (yyvsp[(1) - (3)].string), (yyvsp[(3) - (3)].dim_decl)); CHECK_ERROR; } break; case 45: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 217 "parser.y" + { (yyval.const_decl) = (yyvsp[(1) - (1)].const_decl); } + break; + + case 46: + +/* Line 1806 of yacc.c */ #line 218 "parser.y" - { (yyval.const_decl) = (yyvsp[(1) - (1)].const_decl); ;} - break; - - case 46: - -/* Line 1455 of yacc.c */ -#line 219 "parser.y" - { (yyvsp[(1) - (3)].const_decl)->next = (yyvsp[(3) - (3)].const_decl); (yyval.const_decl) = (yyvsp[(1) - (3)].const_decl); ;} + { (yyvsp[(1) - (3)].const_decl)->next = (yyvsp[(3) - (3)].const_decl); (yyval.const_decl) = (yyvsp[(1) - (3)].const_decl); } break; case 47: -/* Line 1455 of yacc.c */ -#line 222 "parser.y" - { (yyval.const_decl) = new_const_decl(ctx, (yyvsp[(1) - (3)].string), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; ;} +/* Line 1806 of yacc.c */ +#line 221 "parser.y" + { (yyval.const_decl) = new_const_decl(ctx, (yyvsp[(1) - (3)].string), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; } break; case 48: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 224 "parser.y" + { (yyval.expression) = (yyvsp[(1) - (1)].expression); } + break; + + case 49: + +/* Line 1806 of yacc.c */ #line 225 "parser.y" - { (yyval.expression) = (yyvsp[(1) - (1)].expression); ;} - break; - - case 49: - -/* Line 1455 of yacc.c */ -#line 226 "parser.y" - { (yyval.expression) = new_unary_expression(ctx, EXPR_NEG, (yyvsp[(2) - (2)].expression)); CHECK_ERROR; ;} + { (yyval.expression) = new_unary_expression(ctx, EXPR_NEG, (yyvsp[(2) - (2)].expression)); CHECK_ERROR; } break; case 50: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 228 "parser.y" + { (yyval.bool) = TRUE; } + break; + + case 51: + +/* Line 1806 of yacc.c */ #line 229 "parser.y" - { (yyval.bool) = TRUE; ;} - break; - - case 51: - -/* Line 1455 of yacc.c */ -#line 230 "parser.y" - { (yyval.bool) = FALSE; ;} + { (yyval.bool) = FALSE; } break; case 52: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 232 "parser.y" + { (yyval.expression) = NULL;} + break; + + case 53: + +/* Line 1806 of yacc.c */ #line 233 "parser.y" - { (yyval.expression) = NULL;;} - break; - - case 53: - -/* Line 1455 of yacc.c */ -#line 234 "parser.y" - { (yyval.expression) = (yyvsp[(2) - (2)].expression); ;} + { (yyval.expression) = (yyvsp[(2) - (2)].expression); } break; case 54: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 237 "parser.y" + { (yyval.statement) = new_if_statement(ctx, (yyvsp[(2) - (9)].expression), (yyvsp[(5) - (9)].statement), (yyvsp[(6) - (9)].elseif), (yyvsp[(7) - (9)].statement)); CHECK_ERROR; } + break; + + case 55: + +/* Line 1806 of yacc.c */ #line 238 "parser.y" - { (yyval.statement) = new_if_statement(ctx, (yyvsp[(2) - (9)].expression), (yyvsp[(5) - (9)].statement), (yyvsp[(6) - (9)].elseif), (yyvsp[(7) - (9)].statement)); CHECK_ERROR; ;} - break; - - case 55: - -/* Line 1455 of yacc.c */ -#line 239 "parser.y" - { (yyval.statement) = new_if_statement(ctx, (yyvsp[(2) - (4)].expression), (yyvsp[(4) - (4)].statement), NULL, NULL); CHECK_ERROR; ;} + { (yyval.statement) = new_if_statement(ctx, (yyvsp[(2) - (4)].expression), (yyvsp[(4) - (4)].statement), NULL, NULL); CHECK_ERROR; } break; case 56: -/* Line 1455 of yacc.c */ -#line 241 "parser.y" - { (yyval.statement) = new_if_statement(ctx, (yyvsp[(2) - (7)].expression), (yyvsp[(4) - (7)].statement), NULL, (yyvsp[(6) - (7)].statement)); CHECK_ERROR; ;} +/* Line 1806 of yacc.c */ +#line 240 "parser.y" + { (yyval.statement) = new_if_statement(ctx, (yyvsp[(2) - (7)].expression), (yyvsp[(4) - (7)].statement), NULL, (yyvsp[(6) - (7)].statement)); CHECK_ERROR; } break; case 59: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 247 "parser.y" + { (yyval.elseif) = NULL; } + break; + + case 60: + +/* Line 1806 of yacc.c */ #line 248 "parser.y" - { (yyval.elseif) = NULL; ;} - break; - - case 60: - -/* Line 1455 of yacc.c */ -#line 249 "parser.y" - { (yyval.elseif) = (yyvsp[(1) - (1)].elseif); ;} + { (yyval.elseif) = (yyvsp[(1) - (1)].elseif); } break; case 61: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 251 "parser.y" + { (yyval.elseif) = (yyvsp[(1) - (1)].elseif); } + break; + + case 62: + +/* Line 1806 of yacc.c */ #line 252 "parser.y" - { (yyval.elseif) = (yyvsp[(1) - (1)].elseif); ;} - break; - - case 62: - -/* Line 1455 of yacc.c */ -#line 253 "parser.y" - { (yyvsp[(1) - (2)].elseif)->next = (yyvsp[(2) - (2)].elseif); (yyval.elseif) = (yyvsp[(1) - (2)].elseif); ;} + { (yyvsp[(1) - (2)].elseif)->next = (yyvsp[(2) - (2)].elseif); (yyval.elseif) = (yyvsp[(1) - (2)].elseif); } break; case 63: -/* Line 1455 of yacc.c */ -#line 257 "parser.y" - { (yyval.elseif) = new_elseif_decl(ctx, (yyvsp[(2) - (5)].expression), (yyvsp[(5) - (5)].statement)); ;} +/* Line 1806 of yacc.c */ +#line 256 "parser.y" + { (yyval.elseif) = new_elseif_decl(ctx, (yyvsp[(2) - (5)].expression), (yyvsp[(5) - (5)].statement)); } break; case 64: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 259 "parser.y" + { (yyval.statement) = NULL; } + break; + + case 65: + +/* Line 1806 of yacc.c */ #line 260 "parser.y" - { (yyval.statement) = NULL; ;} - break; - - case 65: - -/* Line 1455 of yacc.c */ -#line 261 "parser.y" - { (yyval.statement) = (yyvsp[(3) - (3)].statement); ;} + { (yyval.statement) = (yyvsp[(3) - (3)].statement); } break; case 66: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 263 "parser.y" + { (yyval.case_clausule) = NULL; } + break; + + case 67: + +/* Line 1806 of yacc.c */ #line 264 "parser.y" - { (yyval.case_clausule) = NULL; ;} - break; - - case 67: - -/* Line 1455 of yacc.c */ -#line 265 "parser.y" - { (yyval.case_clausule) = new_case_clausule(ctx, NULL, (yyvsp[(4) - (4)].statement), NULL); ;} + { (yyval.case_clausule) = new_case_clausule(ctx, NULL, (yyvsp[(4) - (4)].statement), NULL); } break; case 68: -/* Line 1455 of yacc.c */ -#line 267 "parser.y" - { (yyval.case_clausule) = new_case_clausule(ctx, (yyvsp[(2) - (5)].expression), (yyvsp[(4) - (5)].statement), (yyvsp[(5) - (5)].case_clausule)); ;} +/* Line 1806 of yacc.c */ +#line 266 "parser.y" + { (yyval.case_clausule) = new_case_clausule(ctx, (yyvsp[(2) - (5)].expression), (yyvsp[(4) - (5)].statement), (yyvsp[(5) - (5)].case_clausule)); } break; case 69: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 269 "parser.y" + { (yyval.expression) = NULL; } + break; + + case 70: + +/* Line 1806 of yacc.c */ #line 270 "parser.y" - { (yyval.expression) = NULL; ;} - break; - - case 70: - -/* Line 1455 of yacc.c */ -#line 271 "parser.y" - { (yyval.expression) = (yyvsp[(2) - (3)].expression); ;} + { (yyval.expression) = (yyvsp[(2) - (3)].expression); } break; case 71: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 273 "parser.y" + { (yyval.expression) = NULL; } + break; + + case 72: + +/* Line 1806 of yacc.c */ #line 274 "parser.y" - { (yyval.expression) = NULL; ;} - break; - - case 72: - -/* Line 1455 of yacc.c */ -#line 275 "parser.y" - { (yyval.expression) = (yyvsp[(1) - (1)].expression); ;} + { (yyval.expression) = (yyvsp[(1) - (1)].expression); } break; case 75: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 281 "parser.y" + { (yyval.expression) = (yyvsp[(1) - (1)].expression); } + break; + + case 76: + +/* Line 1806 of yacc.c */ #line 282 "parser.y" - { (yyval.expression) = (yyvsp[(1) - (1)].expression); ;} - break; - - case 76: - -/* Line 1455 of yacc.c */ -#line 283 "parser.y" - { (yyvsp[(1) - (3)].expression)->next = (yyvsp[(3) - (3)].expression); (yyval.expression) = (yyvsp[(1) - (3)].expression); ;} + { (yyvsp[(1) - (3)].expression)->next = (yyvsp[(3) - (3)].expression); (yyval.expression) = (yyvsp[(1) - (3)].expression); } break; case 77: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 285 "parser.y" + { (yyval.expression) = (yyvsp[(1) - (1)].expression); } + break; + + case 78: + +/* Line 1806 of yacc.c */ #line 286 "parser.y" - { (yyval.expression) = (yyvsp[(1) - (1)].expression); ;} - break; - - case 78: - -/* Line 1455 of yacc.c */ -#line 287 "parser.y" - { (yyval.expression) = new_binary_expression(ctx, EXPR_IMP, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; ;} + { (yyval.expression) = new_binary_expression(ctx, EXPR_IMP, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; } break; case 79: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 289 "parser.y" + { (yyval.expression) = (yyvsp[(1) - (1)].expression); } + break; + + case 80: + +/* Line 1806 of yacc.c */ #line 290 "parser.y" - { (yyval.expression) = (yyvsp[(1) - (1)].expression); ;} - break; - - case 80: - -/* Line 1455 of yacc.c */ -#line 291 "parser.y" - { (yyval.expression) = new_binary_expression(ctx, EXPR_EQV, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; ;} + { (yyval.expression) = new_binary_expression(ctx, EXPR_EQV, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; } break; case 81: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 293 "parser.y" + { (yyval.expression) = (yyvsp[(1) - (1)].expression); } + break; + + case 82: + +/* Line 1806 of yacc.c */ #line 294 "parser.y" - { (yyval.expression) = (yyvsp[(1) - (1)].expression); ;} - break; - - case 82: - -/* Line 1455 of yacc.c */ -#line 295 "parser.y" - { (yyval.expression) = new_binary_expression(ctx, EXPR_XOR, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; ;} + { (yyval.expression) = new_binary_expression(ctx, EXPR_XOR, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; } break; case 83: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 297 "parser.y" + { (yyval.expression) = (yyvsp[(1) - (1)].expression); } + break; + + case 84: + +/* Line 1806 of yacc.c */ #line 298 "parser.y" - { (yyval.expression) = (yyvsp[(1) - (1)].expression); ;} - break; - - case 84: - -/* Line 1455 of yacc.c */ -#line 299 "parser.y" - { (yyval.expression) = new_binary_expression(ctx, EXPR_OR, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; ;} + { (yyval.expression) = new_binary_expression(ctx, EXPR_OR, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; } break; case 85: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 301 "parser.y" + { (yyval.expression) = (yyvsp[(1) - (1)].expression); } + break; + + case 86: + +/* Line 1806 of yacc.c */ #line 302 "parser.y" - { (yyval.expression) = (yyvsp[(1) - (1)].expression); ;} - break; - - case 86: - -/* Line 1455 of yacc.c */ -#line 303 "parser.y" - { (yyval.expression) = new_binary_expression(ctx, EXPR_AND, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; ;} + { (yyval.expression) = new_binary_expression(ctx, EXPR_AND, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; } break; case 87: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 305 "parser.y" + { (yyval.expression) = (yyvsp[(1) - (1)].expression); } + break; + + case 88: + +/* Line 1806 of yacc.c */ #line 306 "parser.y" - { (yyval.expression) = (yyvsp[(1) - (1)].expression); ;} - break; - - case 88: - -/* Line 1455 of yacc.c */ -#line 307 "parser.y" - { (yyval.expression) = new_unary_expression(ctx, EXPR_NOT, (yyvsp[(2) - (2)].expression)); CHECK_ERROR; ;} + { (yyval.expression) = new_unary_expression(ctx, EXPR_NOT, (yyvsp[(2) - (2)].expression)); CHECK_ERROR; } break; case 89: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 309 "parser.y" + { (yyval.expression) = (yyvsp[(1) - (1)].expression); } + break; + + case 90: + +/* Line 1806 of yacc.c */ #line 310 "parser.y" - { (yyval.expression) = (yyvsp[(1) - (1)].expression); ;} - break; - - case 90: - -/* Line 1455 of yacc.c */ + { (yyval.expression) = new_binary_expression(ctx, EXPR_EQUAL, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; } + break; + + case 91: + +/* Line 1806 of yacc.c */ #line 311 "parser.y" - { (yyval.expression) = new_binary_expression(ctx, EXPR_EQUAL, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; ;} - break; - - case 91: - -/* Line 1455 of yacc.c */ + { (yyval.expression) = new_binary_expression(ctx, EXPR_NEQUAL, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; } + break; + + case 92: + +/* Line 1806 of yacc.c */ #line 312 "parser.y" - { (yyval.expression) = new_binary_expression(ctx, EXPR_NEQUAL, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; ;} - break; - - case 92: - -/* Line 1455 of yacc.c */ + { (yyval.expression) = new_binary_expression(ctx, EXPR_GT, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; } + break; + + case 93: + +/* Line 1806 of yacc.c */ #line 313 "parser.y" - { (yyval.expression) = new_binary_expression(ctx, EXPR_GT, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; ;} - break; - - case 93: - -/* Line 1455 of yacc.c */ + { (yyval.expression) = new_binary_expression(ctx, EXPR_LT, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; } + break; + + case 94: + +/* Line 1806 of yacc.c */ #line 314 "parser.y" - { (yyval.expression) = new_binary_expression(ctx, EXPR_LT, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; ;} - break; - - case 94: - -/* Line 1455 of yacc.c */ + { (yyval.expression) = new_binary_expression(ctx, EXPR_GTEQ, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; } + break; + + case 95: + +/* Line 1806 of yacc.c */ #line 315 "parser.y" - { (yyval.expression) = new_binary_expression(ctx, EXPR_GTEQ, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; ;} - break; - - case 95: - -/* Line 1455 of yacc.c */ + { (yyval.expression) = new_binary_expression(ctx, EXPR_LTEQ, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; } + break; + + case 96: + +/* Line 1806 of yacc.c */ #line 316 "parser.y" - { (yyval.expression) = new_binary_expression(ctx, EXPR_LTEQ, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; ;} - break; - - case 96: - -/* Line 1455 of yacc.c */ -#line 317 "parser.y" - { (yyval.expression) = new_binary_expression(ctx, EXPR_IS, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; ;} + { (yyval.expression) = new_binary_expression(ctx, EXPR_IS, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; } break; case 97: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 319 "parser.y" + { (yyval.expression) = (yyvsp[(1) - (1)].expression); } + break; + + case 98: + +/* Line 1806 of yacc.c */ #line 320 "parser.y" - { (yyval.expression) = (yyvsp[(1) - (1)].expression); ;} - break; - - case 98: - -/* Line 1455 of yacc.c */ -#line 321 "parser.y" - { (yyval.expression) = new_binary_expression(ctx, EXPR_CONCAT, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; ;} + { (yyval.expression) = new_binary_expression(ctx, EXPR_CONCAT, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; } break; case 99: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 323 "parser.y" + { (yyval.expression) = (yyvsp[(1) - (1)].expression); } + break; + + case 100: + +/* Line 1806 of yacc.c */ #line 324 "parser.y" - { (yyval.expression) = (yyvsp[(1) - (1)].expression); ;} - break; - - case 100: - -/* Line 1455 of yacc.c */ + { (yyval.expression) = new_binary_expression(ctx, EXPR_ADD, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; } + break; + + case 101: + +/* Line 1806 of yacc.c */ #line 325 "parser.y" - { (yyval.expression) = new_binary_expression(ctx, EXPR_ADD, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; ;} - break; - - case 101: - -/* Line 1455 of yacc.c */ -#line 326 "parser.y" - { (yyval.expression) = new_binary_expression(ctx, EXPR_SUB, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; ;} + { (yyval.expression) = new_binary_expression(ctx, EXPR_SUB, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; } break; case 102: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 328 "parser.y" + { (yyval.expression) = (yyvsp[(1) - (1)].expression); } + break; + + case 103: + +/* Line 1806 of yacc.c */ #line 329 "parser.y" - { (yyval.expression) = (yyvsp[(1) - (1)].expression); ;} - break; - - case 103: - -/* Line 1455 of yacc.c */ -#line 330 "parser.y" - { (yyval.expression) = new_binary_expression(ctx, EXPR_MOD, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; ;} + { (yyval.expression) = new_binary_expression(ctx, EXPR_MOD, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; } break; case 104: -/* Line 1455 of yacc.c */ -#line 333 "parser.y" - { (yyval.expression) = (yyvsp[(1) - (1)].expression); ;} +/* Line 1806 of yacc.c */ +#line 332 "parser.y" + { (yyval.expression) = (yyvsp[(1) - (1)].expression); } break; case 105: -/* Line 1455 of yacc.c */ -#line 335 "parser.y" - { (yyval.expression) = new_binary_expression(ctx, EXPR_IDIV, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; ;} +/* Line 1806 of yacc.c */ +#line 334 "parser.y" + { (yyval.expression) = new_binary_expression(ctx, EXPR_IDIV, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; } break; case 106: -/* Line 1455 of yacc.c */ -#line 338 "parser.y" - { (yyval.expression) = (yyvsp[(1) - (1)].expression); ;} +/* Line 1806 of yacc.c */ +#line 337 "parser.y" + { (yyval.expression) = (yyvsp[(1) - (1)].expression); } break; case 107: -/* Line 1455 of yacc.c */ -#line 340 "parser.y" - { (yyval.expression) = new_binary_expression(ctx, EXPR_MUL, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; ;} +/* Line 1806 of yacc.c */ +#line 339 "parser.y" + { (yyval.expression) = new_binary_expression(ctx, EXPR_MUL, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; } break; case 108: -/* Line 1455 of yacc.c */ -#line 342 "parser.y" - { (yyval.expression) = new_binary_expression(ctx, EXPR_DIV, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; ;} +/* Line 1806 of yacc.c */ +#line 341 "parser.y" + { (yyval.expression) = new_binary_expression(ctx, EXPR_DIV, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; } break; case 109: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 344 "parser.y" + { (yyval.expression) = (yyvsp[(1) - (1)].expression); } + break; + + case 110: + +/* Line 1806 of yacc.c */ #line 345 "parser.y" - { (yyval.expression) = (yyvsp[(1) - (1)].expression); ;} - break; - - case 110: - -/* Line 1455 of yacc.c */ -#line 346 "parser.y" - { (yyval.expression) = new_binary_expression(ctx, EXPR_EXP, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; ;} + { (yyval.expression) = new_binary_expression(ctx, EXPR_EXP, (yyvsp[(1) - (3)].expression), (yyvsp[(3) - (3)].expression)); CHECK_ERROR; } break; case 111: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 348 "parser.y" + { (yyval.expression) = (yyvsp[(1) - (1)].expression); } + break; + + case 112: + +/* Line 1806 of yacc.c */ #line 349 "parser.y" - { (yyval.expression) = (yyvsp[(1) - (1)].expression); ;} - break; - - case 112: - -/* Line 1455 of yacc.c */ + { (yyval.expression) = (yyvsp[(1) - (1)].expression); } + break; + + case 113: + +/* Line 1806 of yacc.c */ #line 350 "parser.y" - { (yyval.expression) = (yyvsp[(1) - (1)].expression); ;} - break; - - case 113: - -/* Line 1455 of yacc.c */ + { (yyval.expression) = new_new_expression(ctx, (yyvsp[(2) - (2)].string)); CHECK_ERROR; } + break; + + case 114: + +/* Line 1806 of yacc.c */ #line 351 "parser.y" - { (yyval.expression) = new_new_expression(ctx, (yyvsp[(2) - (2)].string)); CHECK_ERROR; ;} - break; - - case 114: - -/* Line 1455 of yacc.c */ -#line 352 "parser.y" - { (yyval.expression) = new_unary_expression(ctx, EXPR_NEG, (yyvsp[(2) - (2)].expression)); CHECK_ERROR; ;} + { (yyval.expression) = new_unary_expression(ctx, EXPR_NEG, (yyvsp[(2) - (2)].expression)); CHECK_ERROR; } break; case 115: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 354 "parser.y" + { (yyval.expression) = (yyvsp[(1) - (1)].expression); } + break; + + case 116: + +/* Line 1806 of yacc.c */ #line 355 "parser.y" - { (yyval.expression) = (yyvsp[(1) - (1)].expression); ;} - break; - - case 116: - -/* Line 1455 of yacc.c */ -#line 356 "parser.y" - { (yyvsp[(1) - (2)].member)->args = (yyvsp[(2) - (2)].expression); (yyval.expression) = &(yyvsp[(1) - (2)].member)->expr; ;} + { (yyvsp[(1) - (2)].member)->args = (yyvsp[(2) - (2)].expression); (yyval.expression) = &(yyvsp[(1) - (2)].member)->expr; } break; case 117: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 358 "parser.y" + { (yyval.expression) = new_bool_expression(ctx, VARIANT_TRUE); CHECK_ERROR; } + break; + + case 118: + +/* Line 1806 of yacc.c */ #line 359 "parser.y" - { (yyval.expression) = new_bool_expression(ctx, VARIANT_TRUE); CHECK_ERROR; ;} - break; - - case 118: - -/* Line 1455 of yacc.c */ + { (yyval.expression) = new_bool_expression(ctx, VARIANT_FALSE); CHECK_ERROR; } + break; + + case 119: + +/* Line 1806 of yacc.c */ #line 360 "parser.y" - { (yyval.expression) = new_bool_expression(ctx, VARIANT_FALSE); CHECK_ERROR; ;} - break; - - case 119: - -/* Line 1455 of yacc.c */ + { (yyval.expression) = new_string_expression(ctx, (yyvsp[(1) - (1)].string)); CHECK_ERROR; } + break; + + case 120: + +/* Line 1806 of yacc.c */ #line 361 "parser.y" - { (yyval.expression) = new_string_expression(ctx, (yyvsp[(1) - (1)].string)); CHECK_ERROR; ;} - break; - - case 120: - -/* Line 1455 of yacc.c */ + { (yyval.expression) = (yyvsp[(1) - (1)].expression); } + break; + + case 121: + +/* Line 1806 of yacc.c */ #line 362 "parser.y" - { (yyval.expression) = (yyvsp[(1) - (1)].expression); ;} - break; - - case 121: - -/* Line 1455 of yacc.c */ + { (yyval.expression) = new_expression(ctx, EXPR_EMPTY, 0); CHECK_ERROR; } + break; + + case 122: + +/* Line 1806 of yacc.c */ #line 363 "parser.y" - { (yyval.expression) = new_expression(ctx, EXPR_EMPTY, 0); CHECK_ERROR; ;} - break; - - case 122: - -/* Line 1455 of yacc.c */ + { (yyval.expression) = new_expression(ctx, EXPR_NULL, 0); CHECK_ERROR; } + break; + + case 123: + +/* Line 1806 of yacc.c */ #line 364 "parser.y" - { (yyval.expression) = new_expression(ctx, EXPR_NULL, 0); CHECK_ERROR; ;} - break; - - case 123: - -/* Line 1455 of yacc.c */ -#line 365 "parser.y" - { (yyval.expression) = new_expression(ctx, EXPR_NOTHING, 0); CHECK_ERROR; ;} + { (yyval.expression) = new_expression(ctx, EXPR_NOTHING, 0); CHECK_ERROR; } break; case 124: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 367 "parser.y" + { (yyval.expression) = new_long_expression(ctx, EXPR_USHORT, (yyvsp[(1) - (1)].lng)); CHECK_ERROR; } + break; + + case 125: + +/* Line 1806 of yacc.c */ #line 368 "parser.y" - { (yyval.expression) = new_long_expression(ctx, EXPR_USHORT, (yyvsp[(1) - (1)].lng)); CHECK_ERROR; ;} - break; - - case 125: - -/* Line 1455 of yacc.c */ + { (yyval.expression) = new_long_expression(ctx, EXPR_USHORT, 0); CHECK_ERROR; } + break; + + case 126: + +/* Line 1806 of yacc.c */ #line 369 "parser.y" - { (yyval.expression) = new_long_expression(ctx, EXPR_USHORT, 0); CHECK_ERROR; ;} - break; - - case 126: - -/* Line 1455 of yacc.c */ + { (yyval.expression) = new_long_expression(ctx, EXPR_ULONG, (yyvsp[(1) - (1)].lng)); CHECK_ERROR; } + break; + + case 127: + +/* Line 1806 of yacc.c */ #line 370 "parser.y" - { (yyval.expression) = new_long_expression(ctx, EXPR_ULONG, (yyvsp[(1) - (1)].lng)); CHECK_ERROR; ;} - break; - - case 127: - -/* Line 1455 of yacc.c */ -#line 371 "parser.y" - { (yyval.expression) = new_double_expression(ctx, (yyvsp[(1) - (1)].dbl)); CHECK_ERROR; ;} + { (yyval.expression) = new_double_expression(ctx, (yyvsp[(1) - (1)].dbl)); CHECK_ERROR; } break; case 128: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 374 "parser.y" + { (yyval.expression) = new_unary_expression(ctx, EXPR_BRACKETS, (yyvsp[(2) - (3)].expression)); } + break; + + case 129: + +/* Line 1806 of yacc.c */ #line 375 "parser.y" - { (yyval.expression) = new_unary_expression(ctx, EXPR_BRACKETS, (yyvsp[(2) - (3)].expression)); ;} - break; - - case 129: - -/* Line 1455 of yacc.c */ -#line 376 "parser.y" - { (yyval.expression) = new_expression(ctx, EXPR_ME, 0); CHECK_ERROR; ;} + { (yyval.expression) = new_expression(ctx, EXPR_ME, 0); CHECK_ERROR; } break; case 130: -/* Line 1455 of yacc.c */ -#line 379 "parser.y" - { (yyvsp[(4) - (7)].class_decl)->name = (yyvsp[(2) - (7)].string); (yyval.class_decl) = (yyvsp[(4) - (7)].class_decl); ;} +/* Line 1806 of yacc.c */ +#line 378 "parser.y" + { (yyvsp[(4) - (7)].class_decl)->name = (yyvsp[(2) - (7)].string); (yyval.class_decl) = (yyvsp[(4) - (7)].class_decl); } break; case 131: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 381 "parser.y" + { (yyval.class_decl) = new_class_decl(ctx); } + break; + + case 132: + +/* Line 1806 of yacc.c */ #line 382 "parser.y" - { (yyval.class_decl) = new_class_decl(ctx); ;} - break; - - case 132: - -/* Line 1455 of yacc.c */ + { (yyval.class_decl) = add_class_function(ctx, (yyvsp[(3) - (3)].class_decl), (yyvsp[(1) - (3)].func_decl)); CHECK_ERROR; } + break; + + case 133: + +/* Line 1806 of yacc.c */ #line 383 "parser.y" - { (yyval.class_decl) = add_class_function(ctx, (yyvsp[(3) - (3)].class_decl), (yyvsp[(1) - (3)].func_decl)); CHECK_ERROR; ;} - break; - - case 133: - -/* Line 1455 of yacc.c */ + { (yyval.class_decl) = add_variant_prop(ctx, (yyvsp[(4) - (4)].class_decl), (yyvsp[(2) - (4)].string), (yyvsp[(1) - (4)].uint)); CHECK_ERROR; } + break; + + case 134: + +/* Line 1806 of yacc.c */ #line 384 "parser.y" - { (yyval.class_decl) = add_variant_prop(ctx, (yyvsp[(4) - (4)].class_decl), (yyvsp[(2) - (4)].string), (yyvsp[(1) - (4)].uint)); CHECK_ERROR; ;} - break; - - case 134: - -/* Line 1455 of yacc.c */ -#line 385 "parser.y" - { (yyval.class_decl) = add_class_function(ctx, (yyvsp[(3) - (3)].class_decl), (yyvsp[(1) - (3)].func_decl)); CHECK_ERROR; ;} + { (yyval.class_decl) = add_class_function(ctx, (yyvsp[(3) - (3)].class_decl), (yyvsp[(1) - (3)].func_decl)); CHECK_ERROR; } break; case 135: -/* Line 1455 of yacc.c */ -#line 389 "parser.y" - { (yyval.func_decl) = new_function_decl(ctx, (yyvsp[(4) - (9)].string), FUNC_PROPGET, (yyvsp[(1) - (9)].uint), NULL, (yyvsp[(7) - (9)].statement)); CHECK_ERROR; ;} +/* Line 1806 of yacc.c */ +#line 388 "parser.y" + { (yyval.func_decl) = new_function_decl(ctx, (yyvsp[(4) - (9)].string), FUNC_PROPGET, (yyvsp[(1) - (9)].uint), NULL, (yyvsp[(7) - (9)].statement)); CHECK_ERROR; } break; case 136: -/* Line 1455 of yacc.c */ -#line 391 "parser.y" - { (yyval.func_decl) = new_function_decl(ctx, (yyvsp[(4) - (11)].string), FUNC_PROPLET, (yyvsp[(1) - (11)].uint), (yyvsp[(6) - (11)].arg_decl), (yyvsp[(9) - (11)].statement)); CHECK_ERROR; ;} +/* Line 1806 of yacc.c */ +#line 390 "parser.y" + { (yyval.func_decl) = new_function_decl(ctx, (yyvsp[(4) - (11)].string), FUNC_PROPLET, (yyvsp[(1) - (11)].uint), (yyvsp[(6) - (11)].arg_decl), (yyvsp[(9) - (11)].statement)); CHECK_ERROR; } break; case 137: -/* Line 1455 of yacc.c */ -#line 393 "parser.y" - { (yyval.func_decl) = new_function_decl(ctx, (yyvsp[(4) - (11)].string), FUNC_PROPSET, (yyvsp[(1) - (11)].uint), (yyvsp[(6) - (11)].arg_decl), (yyvsp[(9) - (11)].statement)); CHECK_ERROR; ;} +/* Line 1806 of yacc.c */ +#line 392 "parser.y" + { (yyval.func_decl) = new_function_decl(ctx, (yyvsp[(4) - (11)].string), FUNC_PROPSET, (yyvsp[(1) - (11)].uint), (yyvsp[(6) - (11)].arg_decl), (yyvsp[(9) - (11)].statement)); CHECK_ERROR; } break; case 138: -/* Line 1455 of yacc.c */ -#line 397 "parser.y" - { (yyval.func_decl) = new_function_decl(ctx, (yyvsp[(3) - (8)].string), FUNC_SUB, (yyvsp[(1) - (8)].uint), (yyvsp[(4) - (8)].arg_decl), (yyvsp[(6) - (8)].statement)); CHECK_ERROR; ;} +/* Line 1806 of yacc.c */ +#line 396 "parser.y" + { (yyval.func_decl) = new_function_decl(ctx, (yyvsp[(3) - (8)].string), FUNC_SUB, (yyvsp[(1) - (8)].uint), (yyvsp[(4) - (8)].arg_decl), (yyvsp[(6) - (8)].statement)); CHECK_ERROR; } break; case 139: -/* Line 1455 of yacc.c */ -#line 399 "parser.y" - { (yyval.func_decl) = new_function_decl(ctx, (yyvsp[(3) - (8)].string), FUNC_FUNCTION, (yyvsp[(1) - (8)].uint), (yyvsp[(4) - (8)].arg_decl), (yyvsp[(6) - (8)].statement)); CHECK_ERROR; ;} +/* Line 1806 of yacc.c */ +#line 398 "parser.y" + { (yyval.func_decl) = new_function_decl(ctx, (yyvsp[(3) - (8)].string), FUNC_FUNCTION, (yyvsp[(1) - (8)].uint), (yyvsp[(4) - (8)].arg_decl), (yyvsp[(6) - (8)].statement)); CHECK_ERROR; } break; case 140: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 401 "parser.y" + { (yyval.uint) = 0; } + break; + + case 141: + +/* Line 1806 of yacc.c */ #line 402 "parser.y" - { (yyval.uint) = 0; ;} - break; - - case 141: - -/* Line 1455 of yacc.c */ -#line 403 "parser.y" - { (yyval.uint) = (yyvsp[(1) - (1)].uint); ;} + { (yyval.uint) = (yyvsp[(1) - (1)].uint); } break; case 142: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 405 "parser.y" + { (yyval.uint) = STORAGE_IS_DEFAULT; } + break; + + case 143: + +/* Line 1806 of yacc.c */ #line 406 "parser.y" - { (yyval.uint) = STORAGE_IS_DEFAULT; ;} - break; - - case 143: - -/* Line 1455 of yacc.c */ + { (yyval.uint) = 0; } + break; + + case 144: + +/* Line 1806 of yacc.c */ #line 407 "parser.y" - { (yyval.uint) = 0; ;} - break; - - case 144: - -/* Line 1455 of yacc.c */ -#line 408 "parser.y" - { (yyval.uint) = STORAGE_IS_PRIVATE; ;} + { (yyval.uint) = STORAGE_IS_PRIVATE; } break; case 145: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 410 "parser.y" + { (yyval.arg_decl) = NULL; } + break; + + case 146: + +/* Line 1806 of yacc.c */ #line 411 "parser.y" - { (yyval.arg_decl) = NULL; ;} - break; - - case 146: - -/* Line 1455 of yacc.c */ -#line 412 "parser.y" - { (yyval.arg_decl) = (yyvsp[(2) - (3)].arg_decl); ;} + { (yyval.arg_decl) = (yyvsp[(2) - (3)].arg_decl); } break; case 147: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 414 "parser.y" + { (yyval.arg_decl) = (yyvsp[(1) - (1)].arg_decl); } + break; + + case 148: + +/* Line 1806 of yacc.c */ #line 415 "parser.y" - { (yyval.arg_decl) = (yyvsp[(1) - (1)].arg_decl); ;} - break; - - case 148: - -/* Line 1455 of yacc.c */ -#line 416 "parser.y" - { (yyvsp[(1) - (3)].arg_decl)->next = (yyvsp[(3) - (3)].arg_decl); (yyval.arg_decl) = (yyvsp[(1) - (3)].arg_decl); ;} + { (yyvsp[(1) - (3)].arg_decl)->next = (yyvsp[(3) - (3)].arg_decl); (yyval.arg_decl) = (yyvsp[(1) - (3)].arg_decl); } break; case 149: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 418 "parser.y" + { (yyval.arg_decl) = new_argument_decl(ctx, (yyvsp[(1) - (1)].string), TRUE); } + break; + + case 150: + +/* Line 1806 of yacc.c */ #line 419 "parser.y" - { (yyval.arg_decl) = new_argument_decl(ctx, (yyvsp[(1) - (1)].string), TRUE); ;} - break; - - case 150: - -/* Line 1455 of yacc.c */ + { (yyval.arg_decl) = new_argument_decl(ctx, (yyvsp[(2) - (2)].string), TRUE); } + break; + + case 151: + +/* Line 1806 of yacc.c */ #line 420 "parser.y" - { (yyval.arg_decl) = new_argument_decl(ctx, (yyvsp[(2) - (2)].string), TRUE); ;} - break; - - case 151: - -/* Line 1455 of yacc.c */ -#line 421 "parser.y" - { (yyval.arg_decl) = new_argument_decl(ctx, (yyvsp[(2) - (2)].string), FALSE); ;} + { (yyval.arg_decl) = new_argument_decl(ctx, (yyvsp[(2) - (2)].string), FALSE); } break; case 152: -/* Line 1455 of yacc.c */ +/* Line 1806 of yacc.c */ +#line 424 "parser.y" + { (yyval.string) = (yyvsp[(1) - (1)].string); } + break; + + case 153: + +/* Line 1806 of yacc.c */ #line 425 "parser.y" - { (yyval.string) = (yyvsp[(1) - (1)].string); ;} - break; - - case 153: - -/* Line 1455 of yacc.c */ -#line 426 "parser.y" - { (yyval.string) = propertyW; ;} - break; - - - -/* Line 1455 of yacc.c */ -#line 2907 "parser.tab.c" + { (yyval.string) = propertyW; } + break; + + + +/* Line 1806 of yacc.c */ +#line 2940 "parser.tab.c" default: break; } + /* User semantic actions sometimes alter yychar, and that requires + that yytoken be updated with the new translation. We take the + approach of translating immediately before every use of yytoken. + One alternative is translating here after every semantic action, + but that translation would be missed if the semantic action invokes + YYABORT, YYACCEPT, or YYERROR immediately after altering yychar or + if it invokes YYBACKUP. In the case of YYABORT or YYACCEPT, an + incorrect destructor might then be invoked immediately. In the + case of YYERROR or YYBACKUP, subsequent parser actions might lead + to an incorrect destructor call or verbose syntax error message + before the lookahead is translated. */ YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); YYPOPSTACK (yylen); @@ -2933,44 +2977,47 @@ | yyerrlab -- here on detecting error | `------------------------------------*/ yyerrlab: + /* Make sure we have latest lookahead translation. See comments at + user semantic actions for why this is necessary. */ + yytoken = yychar == YYEMPTY ? YYEMPTY : YYTRANSLATE (yychar); + /* If not already recovering from an error, report this error. */ if (!yyerrstatus) { ++yynerrs; #if ! YYERROR_VERBOSE - yyerror (YY_("syntax error")); + yyerror (ctx, YY_("syntax error")); #else +# define YYSYNTAX_ERROR yysyntax_error (&yymsg_alloc, &yymsg, \ + yyssp, yytoken) { - YYSIZE_T yysize = yysyntax_error (0, yystate, yychar); - if (yymsg_alloc < yysize && yymsg_alloc < YYSTACK_ALLOC_MAXIMUM) - { - YYSIZE_T yyalloc = 2 * yysize; - if (! (yysize <= yyalloc && yyalloc <= YYSTACK_ALLOC_MAXIMUM)) - yyalloc = YYSTACK_ALLOC_MAXIMUM; - if (yymsg != yymsgbuf) - YYSTACK_FREE (yymsg); - yymsg = (char *) YYSTACK_ALLOC (yyalloc); - if (yymsg) - yymsg_alloc = yyalloc; - else - { - yymsg = yymsgbuf; - yymsg_alloc = sizeof yymsgbuf; - } - } - - if (0 < yysize && yysize <= yymsg_alloc) - { - (void) yysyntax_error (yymsg, yystate, yychar); - yyerror (yymsg); - } - else - { - yyerror (YY_("syntax error")); - if (yysize != 0) - goto yyexhaustedlab; - } + char const *yymsgp = YY_("syntax error"); + int yysyntax_error_status; + yysyntax_error_status = YYSYNTAX_ERROR; + if (yysyntax_error_status == 0) + yymsgp = yymsg; + else if (yysyntax_error_status == 1) + { + if (yymsg != yymsgbuf) + YYSTACK_FREE (yymsg); + yymsg = (char *) YYSTACK_ALLOC (yymsg_alloc); + if (!yymsg) + { + yymsg = yymsgbuf; + yymsg_alloc = sizeof yymsgbuf; + yysyntax_error_status = 2; + } + else + { + yysyntax_error_status = YYSYNTAX_ERROR; + yymsgp = yymsg; + } + } + yyerror (ctx, yymsgp); + if (yysyntax_error_status == 2) + goto yyexhaustedlab; } +# undef YYSYNTAX_ERROR #endif } @@ -2990,7 +3037,7 @@ else { yydestruct ("Error: discarding", - yytoken, &yylval); + yytoken, &yylval, ctx); yychar = YYEMPTY; } } @@ -3029,7 +3076,7 @@ for (;;) { yyn = yypact[yystate]; - if (yyn != YYPACT_NINF) + if (!yypact_value_is_default (yyn)) { yyn += YYTERROR; if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR) @@ -3046,7 +3093,7 @@ yydestruct ("Error: popping", - yystos[yystate], yyvsp); + yystos[yystate], yyvsp, ctx); YYPOPSTACK (1); yystate = *yyssp; YY_STACK_PRINT (yyss, yyssp); @@ -3081,15 +3128,20 @@ | yyexhaustedlab -- memory exhaustion comes here. | `-------------------------------------------------*/ yyexhaustedlab: - yyerror (YY_("memory exhausted")); + yyerror (ctx, YY_("memory exhausted")); yyresult = 2; /* Fall through. */ #endif yyreturn: if (yychar != YYEMPTY) - yydestruct ("Cleanup: discarding lookahead", - yytoken, &yylval); + { + /* Make sure we have latest lookahead translation. See comments at + user semantic actions for why this is necessary. */ + yytoken = YYTRANSLATE (yychar); + yydestruct ("Cleanup: discarding lookahead", + yytoken, &yylval, ctx); + } /* Do not reclaim the symbols of the rule which action triggered this YYABORT or YYACCEPT. */ YYPOPSTACK (yylen); @@ -3097,7 +3149,7 @@ while (yyssp != yyss) { yydestruct ("Cleanup: popping", - yystos[*yyssp], yyvsp); + yystos[*yyssp], yyvsp, ctx); YYPOPSTACK (1); } #ifndef yyoverflow @@ -3114,11 +3166,11 @@ -/* Line 1675 of yacc.c */ -#line 427 "parser.y" - - -static int parser_error(const char *str) +/* Line 2067 of yacc.c */ +#line 426 "parser.y" + + +static int parser_error(parser_ctx_t *ctx, const char *str) { return 0; } Modified: trunk/reactos/dll/win32/vbscript/parser.tab.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/vbscript/parser.…
============================================================================== --- trunk/reactos/dll/win32/vbscript/parser.tab.h [iso-8859-1] (original) +++ trunk/reactos/dll/win32/vbscript/parser.tab.h [iso-8859-1] Sat Sep 28 15:12:46 2013 @@ -1,10 +1,8 @@ +/* A Bison parser, made by GNU Bison 2.5. */ -/* A Bison parser, made by GNU Bison 2.4.1. */ - -/* Skeleton interface for Bison's Yacc-like parsers in C +/* Bison interface for Yacc-like parsers in C - Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 - Free Software Foundation, Inc. + Copyright (C) 1984, 1989-1990, 2000-2011 Free Software Foundation, Inc. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -116,8 +114,8 @@ typedef union YYSTYPE { -/* Line 1676 of yacc.c */ -#line 88 "parser.y" +/* Line 2068 of yacc.c */ +#line 87 "parser.y" const WCHAR *string; statement_t *statement; @@ -137,8 +135,8 @@ -/* Line 1676 of yacc.c */ -#line 142 "parser.tab.h" +/* Line 2068 of yacc.c */ +#line 140 "parser.tab.h" } YYSTYPE; # define YYSTYPE_IS_TRIVIAL 1 # define yystype YYSTYPE /* obsolescent; will be withdrawn */ Modified: trunk/reactos/dll/win32/vbscript/parser.y URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/vbscript/parser.…
============================================================================== --- trunk/reactos/dll/win32/vbscript/parser.y [iso-8859-1] (original) +++ trunk/reactos/dll/win32/vbscript/parser.y [iso-8859-1] Sat Sep 28 15:12:46 2013 @@ -25,10 +25,7 @@ WINE_DEFAULT_DEBUG_CHANNEL(vbscript); -#define YYLEX_PARAM ctx -#define YYPARSE_PARAM ctx - -static int parser_error(const char*); +static int parser_error(parser_ctx_t *,const char*); static void parse_complete(parser_ctx_t*,BOOL); @@ -82,7 +79,9 @@ %} -%pure_parser +%lex-param { parser_ctx_t *ctx } +%parse-param { parser_ctx_t *ctx } +%pure-parser %start Program %union { @@ -426,7 +425,7 @@ | tPROPERTY { $$ = propertyW; } %% -static int parser_error(const char *str) +static int parser_error(parser_ctx_t *ctx, const char *str) { return 0; } Modified: trunk/reactos/dll/win32/vbscript/regexp.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/vbscript/regexp.…
============================================================================== --- trunk/reactos/dll/win32/vbscript/regexp.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/vbscript/regexp.c [iso-8859-1] Sat Sep 28 15:12:46 2013 @@ -38,7 +38,7 @@ #include <wine/debug.h> -WINE_DEFAULT_DEBUG_CHANNEL(jscript); +WINE_DEFAULT_DEBUG_CHANNEL(vbscript); /* FIXME: Better error handling */ #define ReportRegExpError(a,b,c) Modified: trunk/reactos/dll/win32/vbscript/vbregexp.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/vbscript/vbregex…
============================================================================== --- trunk/reactos/dll/win32/vbscript/vbregexp.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/vbscript/vbregexp.c [iso-8859-1] Sat Sep 28 15:12:46 2013 @@ -91,6 +91,7 @@ typedef struct Match2 { IMatch2 IMatch2_iface; + IMatch IMatch_iface; LONG ref; @@ -110,6 +111,7 @@ typedef struct MatchCollection2 { IMatchCollection2 IMatchCollection2_iface; + IMatchCollection IMatchCollection_iface; LONG ref; @@ -353,6 +355,9 @@ }else if(IsEqualGUID(riid, &IID_IMatch2)) { TRACE("(%p)->(IID_IMatch2 %p)\n", This, ppv); *ppv = &This->IMatch2_iface; + }else if(IsEqualGUID(riid, &IID_IMatch)) { + TRACE("(%p)->(IID_IMatch %p)\n", This, ppv); + *ppv = &This->IMatch_iface; }else if(IsEqualGUID(riid, &IID_IDispatchEx)) { TRACE("(%p)->(IID_IDispatchEx %p)\n", This, ppv); *ppv = NULL; @@ -509,6 +514,88 @@ Match2_get_SubMatches }; +static inline Match2 *impl_from_IMatch(IMatch *iface) +{ + return CONTAINING_RECORD(iface, Match2, IMatch_iface); +} + +static HRESULT WINAPI Match_QueryInterface(IMatch *iface, REFIID riid, void **ppv) +{ + Match2 *This = impl_from_IMatch(iface); + return IMatch2_QueryInterface(&This->IMatch2_iface, riid, ppv); +} + +static ULONG WINAPI Match_AddRef(IMatch *iface) +{ + Match2 *This = impl_from_IMatch(iface); + return IMatch2_AddRef(&This->IMatch2_iface); +} + +static ULONG WINAPI Match_Release(IMatch *iface) +{ + Match2 *This = impl_from_IMatch(iface); + return IMatch2_Release(&This->IMatch2_iface); +} + +static HRESULT WINAPI Match_GetTypeInfoCount(IMatch *iface, UINT *pctinfo) +{ + Match2 *This = impl_from_IMatch(iface); + return IMatch2_GetTypeInfoCount(&This->IMatch2_iface, pctinfo); +} + +static HRESULT WINAPI Match_GetTypeInfo(IMatch *iface, UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo) +{ + Match2 *This = impl_from_IMatch(iface); + return IMatch2_GetTypeInfo(&This->IMatch2_iface, iTInfo, lcid, ppTInfo); +} + +static HRESULT WINAPI Match_GetIDsOfNames(IMatch *iface, REFIID riid, + LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId) +{ + Match2 *This = impl_from_IMatch(iface); + return IMatch2_GetIDsOfNames(&This->IMatch2_iface, riid, rgszNames, cNames, lcid, rgDispId); +} + +static HRESULT WINAPI Match_Invoke(IMatch *iface, DISPID dispIdMember, + REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, + VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr) +{ + Match2 *This = impl_from_IMatch(iface); + return IMatch2_Invoke(&This->IMatch2_iface, dispIdMember, riid, lcid, + wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr); +} + +static HRESULT WINAPI Match_get_Value(IMatch *iface, BSTR *pValue) +{ + Match2 *This = impl_from_IMatch(iface); + return IMatch2_get_Value(&This->IMatch2_iface, pValue); +} + +static HRESULT WINAPI Match_get_FirstIndex(IMatch *iface, LONG *pFirstIndex) +{ + Match2 *This = impl_from_IMatch(iface); + return IMatch2_get_FirstIndex(&This->IMatch2_iface, pFirstIndex); +} + +static HRESULT WINAPI Match_get_Length(IMatch *iface, LONG *pLength) +{ + Match2 *This = impl_from_IMatch(iface); + return IMatch2_get_Length(&This->IMatch2_iface, pLength); +} + +static IMatchVtbl MatchVtbl = { + Match_QueryInterface, + Match_AddRef, + Match_Release, + Match_GetTypeInfoCount, + Match_GetTypeInfo, + Match_GetIDsOfNames, + Match_Invoke, + Match_get_Value, + Match_get_FirstIndex, + Match_get_Length +}; + static HRESULT create_match2(DWORD pos, match_state_t **result, IMatch2 **match) { Match2 *ret; @@ -532,6 +619,7 @@ *result = NULL; ret->IMatch2_iface.lpVtbl = &Match2Vtbl; + ret->IMatch_iface.lpVtbl = &MatchVtbl; ret->ref = 1; *match = &ret->IMatch2_iface; @@ -700,6 +788,9 @@ }else if(IsEqualGUID(riid, &IID_IMatchCollection2)) { TRACE("(%p)->(IID_IMatchCollection2 %p)\n", This, ppv); *ppv = &This->IMatchCollection2_iface; + }else if(IsEqualGUID(riid, &IID_IMatchCollection)) { + TRACE("(%p)->(IID_IMatchCollection %p)\n", This, ppv); + *ppv = &This->IMatchCollection_iface; }else if(IsEqualGUID(riid, &IID_IDispatchEx)) { TRACE("(%p)->(IID_IDispatchEx %p)\n", This, ppv); *ppv = NULL; @@ -842,6 +933,90 @@ MatchCollection2_get__NewEnum }; +static inline MatchCollection2 *impl_from_IMatchCollection(IMatchCollection *iface) +{ + return CONTAINING_RECORD(iface, MatchCollection2, IMatchCollection_iface); +} + +static HRESULT WINAPI MatchCollection_QueryInterface(IMatchCollection *iface, REFIID riid, void **ppv) +{ + MatchCollection2 *This = impl_from_IMatchCollection(iface); + return IMatchCollection2_QueryInterface(&This->IMatchCollection2_iface, riid, ppv); +} + +static ULONG WINAPI MatchCollection_AddRef(IMatchCollection *iface) +{ + MatchCollection2 *This = impl_from_IMatchCollection(iface); + return IMatchCollection2_AddRef(&This->IMatchCollection2_iface); +} + +static ULONG WINAPI MatchCollection_Release(IMatchCollection *iface) +{ + MatchCollection2 *This = impl_from_IMatchCollection(iface); + return IMatchCollection2_Release(&This->IMatchCollection2_iface); +} + +static HRESULT WINAPI MatchCollection_GetTypeInfoCount(IMatchCollection *iface, UINT *pctinfo) +{ + MatchCollection2 *This = impl_from_IMatchCollection(iface); + return IMatchCollection2_GetTypeInfoCount(&This->IMatchCollection2_iface, pctinfo); +} + +static HRESULT WINAPI MatchCollection_GetTypeInfo(IMatchCollection *iface, + UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo) +{ + MatchCollection2 *This = impl_from_IMatchCollection(iface); + return IMatchCollection2_GetTypeInfo(&This->IMatchCollection2_iface, iTInfo, lcid, ppTInfo); +} + +static HRESULT WINAPI MatchCollection_GetIDsOfNames(IMatchCollection *iface, REFIID riid, + LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId) +{ + MatchCollection2 *This = impl_from_IMatchCollection(iface); + return IMatchCollection2_GetIDsOfNames(&This->IMatchCollection2_iface, + riid, rgszNames, cNames, lcid, rgDispId); +} + +static HRESULT WINAPI MatchCollection_Invoke(IMatchCollection *iface, DISPID dispIdMember, + REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, + EXCEPINFO *pExcepInfo, UINT *puArgErr) +{ + MatchCollection2 *This = impl_from_IMatchCollection(iface); + return IMatchCollection2_Invoke(&This->IMatchCollection2_iface, dispIdMember, + riid, lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr); +} + +static HRESULT WINAPI MatchCollection_get_Item(IMatchCollection *iface, LONG index, IDispatch **ppMatch) +{ + MatchCollection2 *This = impl_from_IMatchCollection(iface); + return IMatchCollection2_get_Item(&This->IMatchCollection2_iface, index, ppMatch); +} + +static HRESULT WINAPI MatchCollection_get_Count(IMatchCollection *iface, LONG *pCount) +{ + MatchCollection2 *This = impl_from_IMatchCollection(iface); + return IMatchCollection2_get_Count(&This->IMatchCollection2_iface, pCount); +} + +static HRESULT WINAPI MatchCollection_get__NewEnum(IMatchCollection *iface, IUnknown **ppEnum) +{ + MatchCollection2 *This = impl_from_IMatchCollection(iface); + return IMatchCollection2_get__NewEnum(&This->IMatchCollection2_iface, ppEnum); +} + +static const IMatchCollectionVtbl MatchCollectionVtbl = { + MatchCollection_QueryInterface, + MatchCollection_AddRef, + MatchCollection_Release, + MatchCollection_GetTypeInfoCount, + MatchCollection_GetTypeInfo, + MatchCollection_GetIDsOfNames, + MatchCollection_Invoke, + MatchCollection_get_Item, + MatchCollection_get_Count, + MatchCollection_get__NewEnum +}; + static HRESULT add_match(IMatchCollection2 *iface, IMatch2 *add) { MatchCollection2 *This = impl_from_IMatchCollection2(iface); @@ -881,6 +1056,7 @@ return E_OUTOFMEMORY; ret->IMatchCollection2_iface.lpVtbl = &MatchCollection2Vtbl; + ret->IMatchCollection_iface.lpVtbl = &MatchCollectionVtbl; ret->ref = 1; *match_collection = &ret->IMatchCollection2_iface; Modified: trunk/reactos/dll/win32/vbscript/vbscript_main.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/vbscript/vbscrip…
============================================================================== --- trunk/reactos/dll/win32/vbscript/vbscript_main.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/vbscript/vbscript_main.c [iso-8859-1] Sat Sep 28 15:12:46 2013 @@ -332,6 +332,7 @@ vbscript_hinstance = hInstDLL; break; case DLL_PROCESS_DETACH: + if (lpv) break; release_typelib(); release_regexp_typelib(); } Modified: trunk/reactos/media/doc/README.WINE URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/media/doc/README.WINE?rev=…
============================================================================== --- trunk/reactos/media/doc/README.WINE [iso-8859-1] (original) +++ trunk/reactos/media/doc/README.WINE [iso-8859-1] Sat Sep 28 15:12:46 2013 @@ -195,7 +195,7 @@ reactos/dll/win32/urlmon # Synced to Wine-1.7.1 reactos/dll/win32/usp10 # Synced to Wine-1.7.1 reactos/dll/win32/uxtheme # Forked -reactos/dll/win32/vbscript # Synced to Wine-1.5.26 +reactos/dll/win32/vbscript # Synced to Wine-1.7.1 reactos/dll/win32/version # Autosync reactos/dll/win32/wbemprox # Synced to Wine-1.5.26 reactos/dll/win32/wer # Autosync
11 years, 2 months
1
0
0
0
[akhaldi] 60419: [USP10_WINETEST] * Speedup build.
by akhaldi@svn.reactos.org
Author: akhaldi Date: Sat Sep 28 15:11:42 2013 New Revision: 60419 URL:
http://svn.reactos.org/svn/reactos?rev=60419&view=rev
Log: [USP10_WINETEST] * Speedup build. Modified: trunk/rostests/winetests/usp10/CMakeLists.txt Modified: trunk/rostests/winetests/usp10/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/usp10/CMakeList…
============================================================================== --- trunk/rostests/winetests/usp10/CMakeLists.txt [iso-8859-1] (original) +++ trunk/rostests/winetests/usp10/CMakeLists.txt [iso-8859-1] Sat Sep 28 15:11:42 2013 @@ -1,10 +1,5 @@ - -add_definitions( - -D__ROS_LONG64__ - -D__WINESRC__) add_executable(usp10_winetest usp10.c testlist.c) -target_link_libraries(usp10_winetest wine) set_module_type(usp10_winetest win32cui) -add_importlibs(usp10_winetest usp10 user32 gdi32 msvcrt kernel32 ntdll) +add_importlibs(usp10_winetest usp10 user32 gdi32 msvcrt kernel32) add_cd_file(TARGET usp10_winetest DESTINATION reactos/bin FOR all)
11 years, 2 months
1
0
0
0
[akhaldi] 60418: [USP10] * Sync with Wine 1.7.1. CORE-7469
by akhaldi@svn.reactos.org
Author: akhaldi Date: Sat Sep 28 15:11:02 2013 New Revision: 60418 URL:
http://svn.reactos.org/svn/reactos?rev=60418&view=rev
Log: [USP10] * Sync with Wine 1.7.1. CORE-7469 Modified: trunk/reactos/dll/win32/usp10/CMakeLists.txt trunk/reactos/dll/win32/usp10/breaking.c trunk/reactos/dll/win32/usp10/indicsyllable.c trunk/reactos/dll/win32/usp10/linebreak.c trunk/reactos/dll/win32/usp10/mirror.c trunk/reactos/dll/win32/usp10/opentype.c trunk/reactos/dll/win32/usp10/shaping.c trunk/reactos/dll/win32/usp10/usp10.c trunk/reactos/media/doc/README.WINE Modified: trunk/reactos/dll/win32/usp10/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/usp10/CMakeLists…
============================================================================== --- trunk/reactos/dll/win32/usp10/CMakeLists.txt [iso-8859-1] (original) +++ trunk/reactos/dll/win32/usp10/CMakeLists.txt [iso-8859-1] Sat Sep 28 15:11:02 2013 @@ -1,7 +1,6 @@ include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine) add_definitions(-D__WINESRC__) - spec2def(usp10.dll usp10.spec ADD_IMPORTLIB) list(APPEND SOURCE @@ -10,21 +9,16 @@ indic.c indicsyllable.c linebreak.c - usp10.c mirror.c opentype.c shape.c shaping.c + usp10.c ${CMAKE_CURRENT_BINARY_DIR}/usp10_stubs.c ${CMAKE_CURRENT_BINARY_DIR}/usp10.def) add_library(usp10 SHARED ${SOURCE}) - set_module_type(usp10 win32dll) - target_link_libraries(usp10 wine) - add_importlibs(usp10 advapi32 user32 gdi32 msvcrt kernel32 ntdll) - - add_cd_file(TARGET usp10 DESTINATION reactos/system32 FOR all) Modified: trunk/reactos/dll/win32/usp10/breaking.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/usp10/breaking.c…
============================================================================== --- trunk/reactos/dll/win32/usp10/breaking.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/usp10/breaking.c [iso-8859-1] Sat Sep 28 15:11:02 2013 @@ -38,7 +38,7 @@ extern const unsigned short wine_linebreak_table[]; -enum breaking_types { b_BK=1, b_CR, b_LF, b_CM, b_SG, b_GL, b_CB, b_SP, b_ZW, b_NL, b_WJ, b_JL, b_JV, b_JT, b_H2, b_H3, b_XX, b_OP, b_CL, b_CP, b_QU, b_NS, b_EX, b_SY, b_IS, b_PR, b_PO, b_NU, b_AL, b_ID, b_IN, b_HY, b_BB, b_BA, b_SA, b_AI, b_B2}; +enum breaking_types { b_BK=1, b_CR, b_LF, b_CM, b_SG, b_GL, b_CB, b_SP, b_ZW, b_NL, b_WJ, b_JL, b_JV, b_JT, b_H2, b_H3, b_XX, b_OP, b_CL, b_CP, b_QU, b_NS, b_EX, b_SY, b_IS, b_PR, b_PO, b_NU, b_AL, b_ID, b_IN, b_HY, b_BB, b_BA, b_SA, b_AI, b_B2, b_HL, b_CJ, b_RI}; enum breaking_class {b_r=1, b_s, b_x}; @@ -97,6 +97,7 @@ break; case b_CM: la[i].fCharStop = FALSE; + break; } } @@ -111,6 +112,10 @@ case b_SG: case b_XX: break_class[i] = b_AL; + break; + case b_CJ: + break_class[i] = b_NS; + break; } } @@ -283,6 +288,16 @@ if (i < count-1) else_break(&break_before[i+1],b_x); break; + /* LB21a */ + case b_HL: + if (i < count-2) + switch (break_class[i+1]) + { + case b_HY: + case b_BA: + else_break(&break_before[i+2], b_x); + } + break; /* LB22 */ case b_IN: if (i > 0) @@ -290,6 +305,7 @@ switch (break_class[i-1]) { case b_AL: + case b_HL: case b_ID: case b_IN: case b_NU: @@ -304,12 +320,16 @@ /* LB23 */ if ((break_class[i] == b_ID && break_class[i+1] == b_PO) || (break_class[i] == b_AL && break_class[i+1] == b_NU) || - (break_class[i] == b_NU && break_class[i+1] == b_AL)) + (break_class[i] == b_HL && break_class[i+1] == b_NU) || + (break_class[i] == b_NU && break_class[i+1] == b_AL) || + (break_class[i] == b_NU && break_class[i+1] == b_HL)) else_break(&break_before[i+1],b_x); /* LB24 */ if ((break_class[i] == b_PR && break_class[i+1] == b_ID) || (break_class[i] == b_PR && break_class[i+1] == b_AL) || - (break_class[i] == b_PO && break_class[i+1] == b_AL)) + (break_class[i] == b_PR && break_class[i+1] == b_HL) || + (break_class[i] == b_PO && break_class[i+1] == b_AL) || + (break_class[i] == b_PO && break_class[i+1] == b_HL)) else_break(&break_before[i+1],b_x); /* LB25 */ @@ -373,19 +393,27 @@ } /* LB28 */ - if (break_class[i] == b_AL && break_class[i+1] == b_AL) + if ((break_class[i] == b_AL && break_class[i+1] == b_AL) || + (break_class[i] == b_AL && break_class[i+1] == b_HL) || + (break_class[i] == b_HL && break_class[i+1] == b_AL) || + (break_class[i] == b_HL && break_class[i+1] == b_HL)) else_break(&break_before[i+1],b_x); /* LB29 */ - if (break_class[i] == b_IS && break_class[i+1] == b_AL) + if ((break_class[i] == b_IS && break_class[i+1] == b_AL) || + (break_class[i] == b_IS && break_class[i+1] == b_HL)) else_break(&break_before[i+1],b_x); /* LB30 */ - if ((break_class[i] == b_AL || break_class[i] == b_NU) && + if ((break_class[i] == b_AL || break_class[i] == b_HL || break_class[i] == b_NU) && break_class[i+1] == b_OP) else_break(&break_before[i+1],b_x); if (break_class[i] == b_CP && - (break_class[i+1] == b_AL || break_class[i] == b_NU)) + (break_class[i+1] == b_AL || break_class[i] == b_HL || break_class[i] == b_NU)) + else_break(&break_before[i+1],b_x); + + /* LB30a */ + if (break_class[i] == b_RI && break_class[i+1] == b_RI) else_break(&break_before[i+1],b_x); } } Modified: trunk/reactos/dll/win32/usp10/indicsyllable.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/usp10/indicsylla…
============================================================================== --- trunk/reactos/dll/win32/usp10/indicsyllable.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/usp10/indicsyllable.c [iso-8859-1] Sat Sep 28 15:11:02 2013 @@ -1,11 +1,11 @@ /* Unicode Indic Syllabic Category */ -/* generated from
http://www.unicode.org/Public/6.0.0/ucd/IndicSyllabicCategory.txt
*/ -/* and from
http://www.unicode.org/Public/6.0.0/ucd/IndicMatraCategory.txt
*/ +/* generated from
http://www.unicode.org/Public/6.2.0/ucd/IndicSyllabicCategory.txt
*/ +/* and from
http://www.unicode.org/Public/6.2.0/ucd/IndicMatraCategory.txt
*/ /* DO NOT EDIT!! */ //#include "wine/unicode.h" -const unsigned short indic_syllabic_table[2624] = +const unsigned short indic_syllabic_table[2704] = { /* level 1 offsets */ 0x0100, 0x0110, 0x0110, 0x0110, 0x0110, 0x0110, 0x0110, 0x0110, @@ -68,19 +68,19 @@ 0x0250, 0x0830, 0x0250, 0x0250, 0x0250, 0x0840, 0x0850, 0x0860, 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, 0x0870, 0x0250, 0x0250, 0x0880, 0x0890, 0x0250, 0x0250, 0x0250, - 0x08a0, 0x0250, 0x08b0, 0x0250, 0x0250, 0x0250, 0x08c0, 0x08d0, - 0x0250, 0x0250, 0x08e0, 0x08f0, 0x0250, 0x0250, 0x0250, 0x0250, - 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, - 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, - 0x0250, 0x0250, 0x0250, 0x0250, 0x0900, 0x0250, 0x0250, 0x0250, - 0x0910, 0x0250, 0x0920, 0x0250, 0x0250, 0x0250, 0x0930, 0x0940, - 0x0950, 0x0250, 0x0250, 0x0960, 0x0970, 0x0250, 0x0250, 0x0250, - 0x0250, 0x0250, 0x0250, 0x0250, 0x0980, 0x0990, 0x0250, 0x0250, - 0x09a0, 0x0250, 0x0250, 0x09b0, 0x09c0, 0x0250, 0x0250, 0x0250, - 0x0250, 0x0250, 0x09d0, 0x09e0, 0x09f0, 0x0250, 0x0250, 0x0a00, - 0x0250, 0x0250, 0x0250, 0x0a10, 0x0a20, 0x0250, 0x0250, 0x0250, - 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, - 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, 0x0a30, 0x0250, + 0x08a0, 0x0250, 0x08b0, 0x08c0, 0x0250, 0x0250, 0x08d0, 0x08e0, + 0x0250, 0x0250, 0x08f0, 0x0900, 0x0250, 0x0250, 0x0250, 0x0250, + 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, 0x0910, + 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, + 0x0250, 0x0250, 0x0250, 0x0250, 0x0920, 0x0250, 0x0250, 0x0250, + 0x0930, 0x0250, 0x0940, 0x0250, 0x0250, 0x0250, 0x0950, 0x0960, + 0x0970, 0x0250, 0x0250, 0x0980, 0x0990, 0x0250, 0x0250, 0x0250, + 0x0250, 0x0250, 0x0250, 0x0250, 0x09a0, 0x09b0, 0x0250, 0x0250, + 0x09c0, 0x0250, 0x0250, 0x09d0, 0x09e0, 0x0250, 0x0250, 0x0250, + 0x0250, 0x0250, 0x09f0, 0x0a00, 0x0a10, 0x0250, 0x0250, 0x0a20, + 0x0250, 0x0250, 0x0250, 0x0a30, 0x0a40, 0x0250, 0x0a50, 0x0a60, + 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, + 0x0250, 0x0250, 0x0250, 0x0250, 0x0250, 0x0a70, 0x0a80, 0x0250, /* values */ 0x4d00, 0x8700, 0x8000, 0x8000, 0x7100, 0x7100, 0x7100, 0x7100, 0x6900, 0x5900, 0x4800, 0x3f00, 0x3000, 0x1f00, 0x1300, 0x0a00, @@ -289,7 +289,9 @@ 0x0001, 0x000c, 0x0002, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x000d, 0x0000, 0x0000, 0x0500, 0x0600, 0x0200, 0x0100, - 0x0500, 0x0500, 0x0105, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0500, 0x0500, 0x0105, 0x0005, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0003, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0004, 0x0007, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0007, 0x0007, 0x0007, 0x0000, 0x0000, 0x0100, 0x0100, 0x0000, 0x0000, 0x0000, 0x0000, @@ -297,6 +299,8 @@ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0100, 0x0200, 0x0200, 0x0000, 0x0100, 0x0100, 0x0607, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0004, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0002, 0x0002, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0009, 0x0000, 0x0000, 0x0000, @@ -336,6 +340,12 @@ 0x0500, 0x0000, 0x0100, 0x0300, 0x0300, 0x0100, 0x0507, 0x0013, 0x0012, 0x0013, 0x0012, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0200, 0x0600, 0x0500, 0x0200, 0x0100, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0002, 0x0e05, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x000a, 0x0006, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0100, 0x0100, 0x0507, 0x0100, 0x0100, 0x0607, 0x0100, 0x0100, 0x0000, 0x0013, 0x0605, 0x0000, 0x0000 }; Modified: trunk/reactos/dll/win32/usp10/linebreak.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/usp10/linebreak.…
============================================================================== --- trunk/reactos/dll/win32/usp10/linebreak.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/usp10/linebreak.c [iso-8859-1] Sat Sep 28 15:11:02 2013 @@ -1,10 +1,10 @@ /* Unicode Line Break Properties */ -/* generated from
http://www.unicode.org/Public/6.0.0/ucd/LineBreak.txt
*/ +/* generated from
http://www.unicode.org/Public/6.2.0/ucd/LineBreak.txt
*/ /* DO NOT EDIT!! */ //#include "wine/unicode.h" -const unsigned short wine_linebreak_table[6800] = +const unsigned short wine_linebreak_table[7056] = { /* level 1 offsets */ 0x0100, 0x0110, 0x0120, 0x0130, 0x0140, 0x0150, 0x0160, 0x0170, @@ -51,137 +51,137 @@ 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x06a0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x06b0, 0x06c0, 0x05b0, 0x06d0, 0x06c0, 0x05b0, - 0x06e0, 0x06f0, 0x0580, 0x0700, 0x0710, 0x05b0, 0x0720, 0x0730, - 0x0740, 0x0750, 0x05b0, 0x05b0, 0x0760, 0x0580, 0x0770, 0x0780, - 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x0790, 0x07a0, 0x07b0, - 0x07c0, 0x07d0, 0x05b0, 0x0580, 0x07e0, 0x05b0, 0x05b0, 0x05b0, - 0x05b0, 0x05b0, 0x07f0, 0x0800, 0x07b0, 0x05b0, 0x0760, 0x0810, - 0x05b0, 0x0820, 0x0830, 0x0840, 0x05b0, 0x0850, 0x0860, 0x0860, - 0x0860, 0x0860, 0x0860, 0x0860, 0x0860, 0x0860, 0x0860, 0x0860, - 0x0870, 0x05b0, 0x05b0, 0x0880, 0x0580, 0x0890, 0x08a0, 0x08b0, - 0x08c0, 0x08d0, 0x08e0, 0x08f0, 0x0900, 0x0910, 0x0920, 0x0930, - 0x0940, 0x08d0, 0x08e0, 0x0950, 0x0960, 0x0970, 0x0980, 0x0990, - 0x09a0, 0x0690, 0x08e0, 0x09b0, 0x09c0, 0x09d0, 0x0920, 0x09e0, - 0x08c0, 0x08d0, 0x08e0, 0x09b0, 0x09f0, 0x0a00, 0x0920, 0x06b0, - 0x0a10, 0x0a20, 0x0a30, 0x0a40, 0x0a50, 0x0a60, 0x0980, 0x0a70, - 0x0a80, 0x0a90, 0x08e0, 0x0aa0, 0x0ab0, 0x0ac0, 0x0920, 0x0ad0, - 0x0ae0, 0x0a90, 0x08e0, 0x0af0, 0x0ab0, 0x0b00, 0x0920, 0x0b10, - 0x0ae0, 0x0a90, 0x05b0, 0x0b20, 0x0b30, 0x0b40, 0x0920, 0x0b50, - 0x0b60, 0x0b70, 0x05b0, 0x0b80, 0x0b90, 0x0ba0, 0x0860, 0x0bb0, - 0x0bc0, 0x0bd0, 0x0bd0, 0x0be0, 0x0bf0, 0x0c00, 0x0860, 0x0860, - 0x0c10, 0x0c20, 0x0c30, 0x0c40, 0x0c50, 0x0c60, 0x0860, 0x0860, - 0x0c70, 0x0c80, 0x07b0, 0x0c90, 0x08b0, 0x05b0, 0x0ca0, 0x0cb0, - 0x0cc0, 0x0cd0, 0x0580, 0x0ce0, 0x0cf0, 0x0d00, 0x0860, 0x0860, - 0x0bd0, 0x0bd0, 0x0bd0, 0x0bd0, 0x0d10, 0x0bd0, 0x0bd0, 0x0bd0, - 0x0bd0, 0x0d20, 0x05b0, 0x05b0, 0x0d30, 0x05b0, 0x05b0, 0x0ca0, - 0x0d40, 0x0d40, 0x0d40, 0x0d40, 0x0d40, 0x0d40, 0x0d50, 0x0d50, - 0x0d50, 0x0d50, 0x0d60, 0x0d70, 0x0d70, 0x0d70, 0x0d70, 0x0d70, - 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x0d80, 0x0d90, 0x05b0, 0x05b0, - 0x0d80, 0x05b0, 0x05b0, 0x0da0, 0x0db0, 0x0dc0, 0x05b0, 0x05b0, - 0x05b0, 0x0db0, 0x05b0, 0x05b0, 0x05b0, 0x0dd0, 0x0de0, 0x0ca0, - 0x05b0, 0x0df0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x0730, - 0x0e00, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, + 0x06e0, 0x06f0, 0x0580, 0x0700, 0x0710, 0x0720, 0x0730, 0x0740, + 0x0750, 0x0760, 0x05b0, 0x05b0, 0x0770, 0x0580, 0x0780, 0x0790, + 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x07a0, 0x07b0, 0x07c0, + 0x07d0, 0x07e0, 0x05b0, 0x0580, 0x07f0, 0x05b0, 0x05b0, 0x05b0, + 0x05b0, 0x05b0, 0x0800, 0x0810, 0x07c0, 0x05b0, 0x0770, 0x0820, + 0x05b0, 0x0830, 0x0840, 0x0850, 0x05b0, 0x0860, 0x0870, 0x0870, + 0x0870, 0x0870, 0x0880, 0x0870, 0x0870, 0x0870, 0x0890, 0x08a0, + 0x08b0, 0x05b0, 0x05b0, 0x08c0, 0x0580, 0x08d0, 0x08e0, 0x08f0, + 0x0900, 0x0910, 0x0920, 0x0930, 0x0940, 0x0950, 0x0960, 0x0970, + 0x0980, 0x0910, 0x0920, 0x0990, 0x09a0, 0x09b0, 0x09c0, 0x09d0, + 0x09e0, 0x0690, 0x0920, 0x09f0, 0x0a00, 0x0a10, 0x0960, 0x0a20, + 0x0900, 0x0910, 0x0920, 0x09f0, 0x0a30, 0x0a40, 0x0960, 0x06b0, + 0x0a50, 0x0a60, 0x0a70, 0x0a80, 0x0a90, 0x0aa0, 0x09c0, 0x0ab0, + 0x0ac0, 0x0ad0, 0x0920, 0x0ae0, 0x0af0, 0x0b00, 0x0960, 0x0b10, + 0x0b20, 0x0ad0, 0x0920, 0x0b30, 0x0af0, 0x0b40, 0x0960, 0x0b50, + 0x0b20, 0x0ad0, 0x05b0, 0x0b60, 0x0b70, 0x0b80, 0x0960, 0x0b90, + 0x0ba0, 0x0bb0, 0x05b0, 0x0bc0, 0x0bd0, 0x0be0, 0x0870, 0x0bf0, + 0x0c00, 0x0c10, 0x0c10, 0x0c20, 0x0c30, 0x0c40, 0x0870, 0x0870, + 0x0c50, 0x0c60, 0x0c70, 0x0c80, 0x0c90, 0x0ca0, 0x0870, 0x0870, + 0x0cb0, 0x0cc0, 0x07c0, 0x0cd0, 0x08f0, 0x05b0, 0x0ce0, 0x0cf0, + 0x0d00, 0x0d10, 0x0580, 0x0d20, 0x0d30, 0x0d40, 0x0870, 0x0870, + 0x0c10, 0x0c10, 0x0c10, 0x0c10, 0x0d50, 0x0c10, 0x0c10, 0x0c10, + 0x0c10, 0x0d60, 0x05b0, 0x05b0, 0x0d70, 0x05b0, 0x05b0, 0x05b0, + 0x0d80, 0x0d80, 0x0d80, 0x0d80, 0x0d80, 0x0d80, 0x0d90, 0x0d90, + 0x0d90, 0x0d90, 0x0da0, 0x0db0, 0x0db0, 0x0db0, 0x0db0, 0x0db0, + 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x0dc0, 0x0dd0, 0x05b0, 0x05b0, + 0x0dc0, 0x05b0, 0x05b0, 0x0de0, 0x0df0, 0x0e00, 0x05b0, 0x05b0, + 0x05b0, 0x0df0, 0x05b0, 0x05b0, 0x05b0, 0x0e10, 0x0e20, 0x0ce0, + 0x05b0, 0x0e30, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x0e40, + 0x0e50, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, - 0x0e00, 0x0e10, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x0e20, 0x09d0, - 0x0e30, 0x0e40, 0x05b0, 0x0e50, 0x05b0, 0x0e60, 0x0e30, 0x0e70, - 0x0bd0, 0x0bd0, 0x0bd0, 0x0bd0, 0x0bd0, 0x0e80, 0x0e90, 0x0df0, - 0x0ea0, 0x0e90, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x06b0, - 0x05b0, 0x05b0, 0x0eb0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x0d30, - 0x05b0, 0x0ca0, 0x0ec0, 0x0ec0, 0x0ed0, 0x0bd0, 0x0ee0, 0x0ef0, - 0x0bd0, 0x0bd0, 0x0f00, 0x0bd0, 0x0f10, 0x0f20, 0x05b0, 0x05b0, - 0x05b0, 0x0f30, 0x0bd0, 0x0bd0, 0x0bd0, 0x0f40, 0x0bd0, 0x0f50, - 0x0e90, 0x0e90, 0x0ee0, 0x0860, 0x0860, 0x0860, 0x0860, 0x0860, - 0x0f60, 0x05b0, 0x05b0, 0x0f70, 0x0f80, 0x0f90, 0x0fa0, 0x0fb0, - 0x0fc0, 0x05b0, 0x0fd0, 0x0e90, 0x05b0, 0x05b0, 0x07f0, 0x0fe0, - 0x05b0, 0x05b0, 0x0f70, 0x0ff0, 0x1000, 0x07b0, 0x05b0, 0x1010, - 0x0860, 0x0860, 0x0860, 0x0860, 0x0860, 0x1020, 0x1030, 0x1040, + 0x0e50, 0x0e60, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x0e70, 0x0a10, + 0x0e80, 0x0e90, 0x05b0, 0x0ea0, 0x05b0, 0x0eb0, 0x0e80, 0x0ec0, + 0x0c10, 0x0c10, 0x0c10, 0x0c10, 0x0c10, 0x0ed0, 0x0ee0, 0x0e30, + 0x0ef0, 0x0ee0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x06b0, + 0x05b0, 0x05b0, 0x0f00, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x0f10, + 0x05b0, 0x0ce0, 0x0f20, 0x0f20, 0x0f30, 0x0c10, 0x0f40, 0x0f50, + 0x0c10, 0x0c10, 0x0f60, 0x0c10, 0x0f70, 0x0f80, 0x05b0, 0x05b0, + 0x05b0, 0x0f90, 0x0c10, 0x0c10, 0x0c10, 0x0fa0, 0x0c10, 0x0fb0, + 0x0ee0, 0x0ee0, 0x0f40, 0x0870, 0x0870, 0x0870, 0x0870, 0x0870, + 0x0fc0, 0x05b0, 0x05b0, 0x0fd0, 0x0fe0, 0x0ff0, 0x1000, 0x1010, + 0x1020, 0x05b0, 0x1030, 0x07c0, 0x05b0, 0x05b0, 0x0800, 0x1040, + 0x05b0, 0x05b0, 0x0fd0, 0x1050, 0x1060, 0x07c0, 0x05b0, 0x1070, + 0x0870, 0x0870, 0x0870, 0x0870, 0x06b0, 0x1080, 0x1090, 0x10a0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, - 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x0580, 0x0580, 0x1050, 0x1060, - 0x05b0, 0x1070, 0x05b0, 0x05b0, 0x1070, 0x1080, 0x05b0, 0x1090, - 0x05b0, 0x05b0, 0x05b0, 0x10a0, 0x10a0, 0x10b0, 0x05b0, 0x10c0, - 0x10d0, 0x10e0, 0x10f0, 0x1100, 0x1110, 0x1120, 0x1130, 0x1140, - 0x1150, 0x0ca0, 0x1160, 0x1170, 0x0860, 0x0580, 0x0580, 0x1180, - 0x1190, 0x11a0, 0x11b0, 0x05b0, 0x05b0, 0x11c0, 0x11d0, 0x11e0, - 0x11f0, 0x11e0, 0x05b0, 0x05b0, 0x05b0, 0x1200, 0x05b0, 0x05b0, - 0x1210, 0x1220, 0x1230, 0x1240, 0x1250, 0x1260, 0x1270, 0x05b0, - 0x1280, 0x1290, 0x12a0, 0x12b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, - 0x05b0, 0x1260, 0x12c0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, - 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x12d0, - 0x05b0, 0x05b0, 0x12e0, 0x0860, 0x0720, 0x0860, 0x12f0, 0x12f0, - 0x12f0, 0x12f0, 0x12f0, 0x12f0, 0x12f0, 0x12f0, 0x12f0, 0x1300, - 0x12f0, 0x12f0, 0x12f0, 0x12f0, 0x11d0, 0x12f0, 0x12f0, 0x1310, - 0x12f0, 0x1320, 0x1330, 0x1340, 0x1350, 0x1360, 0x1370, 0x05b0, - 0x1380, 0x1390, 0x05b0, 0x05b0, 0x13a0, 0x05b0, 0x13b0, 0x05b0, - 0x05b0, 0x13c0, 0x05b0, 0x13c0, 0x13d0, 0x12f0, 0x13e0, 0x12f0, - 0x06c0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x13f0, 0x1400, 0x1410, - 0x12f0, 0x1420, 0x05b0, 0x05b0, 0x1430, 0x05b0, 0x1440, 0x05b0, + 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x0580, 0x0580, 0x10b0, 0x10c0, + 0x05b0, 0x10d0, 0x05b0, 0x05b0, 0x10d0, 0x10e0, 0x05b0, 0x10f0, + 0x05b0, 0x05b0, 0x05b0, 0x1100, 0x1100, 0x1110, 0x05b0, 0x1120, + 0x1130, 0x1140, 0x1150, 0x1160, 0x1170, 0x1180, 0x1190, 0x11a0, + 0x11b0, 0x0ce0, 0x11c0, 0x11d0, 0x0870, 0x0580, 0x0580, 0x11e0, + 0x11f0, 0x1200, 0x1210, 0x05b0, 0x05b0, 0x1220, 0x1230, 0x1240, + 0x1250, 0x1240, 0x05b0, 0x05b0, 0x05b0, 0x1260, 0x05b0, 0x05b0, + 0x1270, 0x1280, 0x1290, 0x12a0, 0x12b0, 0x12c0, 0x12d0, 0x05b0, + 0x12e0, 0x12f0, 0x1300, 0x1310, 0x05b0, 0x05b0, 0x05b0, 0x05b0, + 0x05b0, 0x1320, 0x1330, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, + 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x1340, + 0x05b0, 0x05b0, 0x1350, 0x0870, 0x1360, 0x0870, 0x1370, 0x1370, + 0x1370, 0x1370, 0x1370, 0x1370, 0x1370, 0x1370, 0x1370, 0x1380, + 0x1370, 0x1370, 0x1370, 0x1370, 0x1230, 0x1370, 0x1370, 0x1390, + 0x1370, 0x13a0, 0x13b0, 0x13c0, 0x13d0, 0x13e0, 0x13f0, 0x05b0, + 0x1400, 0x1410, 0x05b0, 0x1420, 0x1430, 0x05b0, 0x1440, 0x1450, + 0x05b0, 0x1460, 0x05b0, 0x1470, 0x1480, 0x1490, 0x14a0, 0x14b0, + 0x14c0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x14d0, 0x14e0, 0x14f0, + 0x1370, 0x1500, 0x05b0, 0x05b0, 0x1510, 0x05b0, 0x1520, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, - 0x1450, 0x1460, 0x05b0, 0x05b0, 0x05b0, 0x1470, 0x05b0, 0x1480, - 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x0ca0, 0x1490, 0x0860, 0x0860, - 0x0860, 0x0860, 0x0860, 0x0860, 0x0860, 0x0860, 0x0860, 0x0860, - 0x05b0, 0x05b0, 0x0840, 0x05b0, 0x05b0, 0x0840, 0x05b0, 0x05b0, - 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x14a0, 0x14b0, - 0x05b0, 0x05b0, 0x0d30, 0x05b0, 0x05b0, 0x05b0, 0x14c0, 0x14d0, - 0x05b0, 0x12e0, 0x14e0, 0x14e0, 0x14e0, 0x14e0, 0x0580, 0x0580, - 0x14f0, 0x1500, 0x1510, 0x1520, 0x0860, 0x0860, 0x0860, 0x0860, - 0x1530, 0x1540, 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, 0x1550, - 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, - 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, 0x1560, 0x0860, 0x1570, - 0x1580, 0x1590, 0x15a0, 0x15b0, 0x15c0, 0x1530, 0x15d0, 0x1530, - 0x15e0, 0x15f0, 0x1600, 0x1530, 0x15d0, 0x1530, 0x15e0, 0x1610, - 0x1620, 0x1530, 0x1630, 0x1640, 0x1530, 0x1530, 0x1530, 0x1530, - 0x1650, 0x1530, 0x1530, 0x1660, 0x1530, 0x1530, 0x1550, 0x1670, - 0x1530, 0x1650, 0x1530, 0x1530, 0x1680, 0x1530, 0x1530, 0x1530, - 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, 0x1650, - 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, - 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, - 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, - 0x1530, 0x1530, 0x1530, 0x1530, 0x05b0, 0x05b0, 0x05b0, 0x05b0, - 0x1530, 0x1690, 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, - 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, - 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, 0x1530, - 0x16a0, 0x1530, 0x1530, 0x1530, 0x16b0, 0x05b0, 0x05b0, 0x1010, - 0x16c0, 0x05b0, 0x16d0, 0x0860, 0x05b0, 0x05b0, 0x14a0, 0x16e0, - 0x05b0, 0x06b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x16f0, + 0x1530, 0x1540, 0x05b0, 0x05b0, 0x05b0, 0x1550, 0x05b0, 0x1560, + 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x0ce0, 0x1570, 0x0870, 0x0870, + 0x0870, 0x0870, 0x0870, 0x0870, 0x0870, 0x0870, 0x0870, 0x0870, + 0x05b0, 0x05b0, 0x0850, 0x05b0, 0x05b0, 0x0850, 0x05b0, 0x05b0, + 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x1580, 0x1590, + 0x05b0, 0x05b0, 0x0d70, 0x05b0, 0x05b0, 0x05b0, 0x15a0, 0x15b0, + 0x05b0, 0x1350, 0x15c0, 0x15c0, 0x15c0, 0x15c0, 0x0580, 0x0580, + 0x15d0, 0x15e0, 0x15f0, 0x1600, 0x0870, 0x0870, 0x0870, 0x0870, + 0x1610, 0x1620, 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, 0x1340, + 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, + 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, 0x1630, 0x0870, 0x1640, + 0x1650, 0x1660, 0x1670, 0x1680, 0x1690, 0x1610, 0x16a0, 0x1610, + 0x16b0, 0x16c0, 0x16d0, 0x1610, 0x16a0, 0x1610, 0x16b0, 0x16e0, + 0x16f0, 0x1610, 0x1700, 0x1710, 0x1610, 0x1610, 0x1610, 0x1610, + 0x1720, 0x1610, 0x1610, 0x1730, 0x1610, 0x1610, 0x1340, 0x1740, + 0x1610, 0x1720, 0x1610, 0x1610, 0x1750, 0x1610, 0x1610, 0x1610, + 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, 0x1720, + 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, + 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, + 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, + 0x1610, 0x1610, 0x1610, 0x1610, 0x05b0, 0x05b0, 0x05b0, 0x05b0, + 0x1610, 0x1760, 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, + 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, + 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, 0x1610, + 0x1770, 0x1610, 0x1610, 0x1610, 0x1780, 0x05b0, 0x05b0, 0x1070, + 0x1790, 0x05b0, 0x17a0, 0x0870, 0x05b0, 0x05b0, 0x1580, 0x17b0, + 0x05b0, 0x17c0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x17d0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, - 0x0840, 0x1700, 0x0df0, 0x0860, 0x0860, 0x0860, 0x0860, 0x1710, - 0x1720, 0x05b0, 0x1730, 0x1740, 0x05b0, 0x05b0, 0x05b0, 0x1750, - 0x1760, 0x05b0, 0x05b0, 0x0f70, 0x1770, 0x0e90, 0x0580, 0x1780, - 0x07b0, 0x05b0, 0x1790, 0x05b0, 0x17a0, 0x17b0, 0x0d40, 0x17c0, - 0x0870, 0x05b0, 0x05b0, 0x17d0, 0x17e0, 0x17f0, 0x0860, 0x0860, - 0x05b0, 0x05b0, 0x1800, 0x1050, 0x1810, 0x1820, 0x0bd0, 0x0f00, - 0x0bd0, 0x0bd0, 0x0bd0, 0x0bd0, 0x1830, 0x1840, 0x0860, 0x0860, - 0x1850, 0x1860, 0x14e0, 0x0860, 0x0860, 0x0860, 0x0860, 0x0860, - 0x0860, 0x0860, 0x0860, 0x0860, 0x05b0, 0x05b0, 0x1870, 0x0e90, - 0x1880, 0x1890, 0x18a0, 0x18b0, 0x18a0, 0x18c0, 0x18a0, 0x1880, - 0x1890, 0x18a0, 0x18b0, 0x18a0, 0x18c0, 0x18a0, 0x1880, 0x1890, - 0x18a0, 0x18b0, 0x18a0, 0x18c0, 0x18a0, 0x1880, 0x1890, 0x18a0, - 0x18b0, 0x18a0, 0x18c0, 0x18a0, 0x1880, 0x1890, 0x18a0, 0x18b0, - 0x18a0, 0x18c0, 0x18a0, 0x1880, 0x1890, 0x18a0, 0x18b0, 0x18a0, - 0x18c0, 0x18a0, 0x1880, 0x1890, 0x18a0, 0x18b0, 0x18a0, 0x18c0, - 0x18a0, 0x1880, 0x1890, 0x18a0, 0x18b0, 0x18a0, 0x18c0, 0x18a0, - 0x1880, 0x1890, 0x18a0, 0x18b0, 0x18a0, 0x18c0, 0x18a0, 0x1880, - 0x1890, 0x18a0, 0x18b0, 0x18a0, 0x18c0, 0x18a0, 0x1880, 0x1890, - 0x18a0, 0x18b0, 0x18a0, 0x18c0, 0x18a0, 0x1880, 0x1890, 0x18a0, - 0x18b0, 0x18a0, 0x18c0, 0x18a0, 0x1880, 0x1890, 0x18a0, 0x18b0, - 0x18a0, 0x18c0, 0x18a0, 0x1880, 0x1890, 0x18a0, 0x18b0, 0x18a0, - 0x18c0, 0x18a0, 0x1880, 0x1890, 0x18a0, 0x18b0, 0x18a0, 0x18c0, - 0x18a0, 0x1880, 0x1890, 0x18a0, 0x18b0, 0x18a0, 0x18c0, 0x18a0, - 0x18a0, 0x18b0, 0x18a0, 0x18c0, 0x18a0, 0x1880, 0x1890, 0x18a0, - 0x18b0, 0x18a0, 0x18d0, 0x0d50, 0x18e0, 0x0d70, 0x0d70, 0x18f0, - 0x1900, 0x1900, 0x1900, 0x1900, 0x1900, 0x1900, 0x1900, 0x1900, - 0x1900, 0x1900, 0x1900, 0x1900, 0x1900, 0x1900, 0x1900, 0x1900, - 0x0860, 0x0860, 0x0860, 0x0860, 0x0860, 0x0860, 0x0860, 0x0860, - 0x0860, 0x0860, 0x0860, 0x0860, 0x0860, 0x0860, 0x0860, 0x0860, - 0x12e0, 0x1910, 0x05b0, 0x1920, 0x1930, 0x05b0, 0x05b0, 0x05b0, - 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x1700, 0x1940, 0x05b0, 0x05b0, - 0x05b0, 0x05b0, 0x05b0, 0x1950, 0x0860, 0x05b0, 0x05b0, 0x05b0, - 0x05b0, 0x1960, 0x05b0, 0x05b0, 0x06b0, 0x0860, 0x0860, 0x1970, - 0x0580, 0x1980, 0x1050, 0x1990, 0x19a0, 0x19b0, 0x19c0, 0x10a0, - 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x19d0, - 0x19e0, 0x19f0, 0x1530, 0x1a00, 0x1530, 0x1a10, 0x1a20, 0x1a30, - 0x05b0, 0x1a40, 0x05b0, 0x0840, 0x1a50, 0x1a60, 0x1a70, 0x1a80, + 0x0850, 0x17e0, 0x1360, 0x0870, 0x0870, 0x0870, 0x0870, 0x0b10, + 0x17f0, 0x05b0, 0x1800, 0x1810, 0x05b0, 0x05b0, 0x05b0, 0x1820, + 0x1830, 0x05b0, 0x05b0, 0x0fd0, 0x1840, 0x0ee0, 0x0580, 0x1850, + 0x07c0, 0x05b0, 0x1860, 0x05b0, 0x1870, 0x1880, 0x0d80, 0x1890, + 0x08b0, 0x05b0, 0x05b0, 0x18a0, 0x18b0, 0x18c0, 0x0870, 0x0870, + 0x05b0, 0x05b0, 0x18d0, 0x10b0, 0x18e0, 0x18f0, 0x0c10, 0x0f60, + 0x0c10, 0x0c10, 0x0c10, 0x0c10, 0x1900, 0x1910, 0x0770, 0x1920, + 0x1930, 0x1940, 0x15c0, 0x0870, 0x0870, 0x0870, 0x0870, 0x0870, + 0x0870, 0x0870, 0x0870, 0x0870, 0x05b0, 0x05b0, 0x1950, 0x0ee0, + 0x1960, 0x1970, 0x1980, 0x1990, 0x1980, 0x19a0, 0x1980, 0x1960, + 0x1970, 0x1980, 0x1990, 0x1980, 0x19a0, 0x1980, 0x1960, 0x1970, + 0x1980, 0x1990, 0x1980, 0x19a0, 0x1980, 0x1960, 0x1970, 0x1980, + 0x1990, 0x1980, 0x19a0, 0x1980, 0x1960, 0x1970, 0x1980, 0x1990, + 0x1980, 0x19a0, 0x1980, 0x1960, 0x1970, 0x1980, 0x1990, 0x1980, + 0x19a0, 0x1980, 0x1960, 0x1970, 0x1980, 0x1990, 0x1980, 0x19a0, + 0x1980, 0x1960, 0x1970, 0x1980, 0x1990, 0x1980, 0x19a0, 0x1980, + 0x1960, 0x1970, 0x1980, 0x1990, 0x1980, 0x19a0, 0x1980, 0x1960, + 0x1970, 0x1980, 0x1990, 0x1980, 0x19a0, 0x1980, 0x1960, 0x1970, + 0x1980, 0x1990, 0x1980, 0x19a0, 0x1980, 0x1960, 0x1970, 0x1980, + 0x1990, 0x1980, 0x19a0, 0x1980, 0x1960, 0x1970, 0x1980, 0x1990, + 0x1980, 0x19a0, 0x1980, 0x1960, 0x1970, 0x1980, 0x1990, 0x1980, + 0x19a0, 0x1980, 0x1960, 0x1970, 0x1980, 0x1990, 0x1980, 0x19a0, + 0x1980, 0x1960, 0x1970, 0x1980, 0x1990, 0x1980, 0x19a0, 0x1980, + 0x1980, 0x1990, 0x1980, 0x19a0, 0x1980, 0x1960, 0x1970, 0x1980, + 0x1990, 0x1980, 0x19b0, 0x0d90, 0x19c0, 0x0db0, 0x0db0, 0x19d0, + 0x19e0, 0x19e0, 0x19e0, 0x19e0, 0x19e0, 0x19e0, 0x19e0, 0x19e0, + 0x19e0, 0x19e0, 0x19e0, 0x19e0, 0x19e0, 0x19e0, 0x19e0, 0x19e0, + 0x0870, 0x0870, 0x0870, 0x0870, 0x0870, 0x0870, 0x0870, 0x0870, + 0x0870, 0x0870, 0x0870, 0x0870, 0x0870, 0x0870, 0x0870, 0x0870, + 0x1350, 0x19f0, 0x1a00, 0x1a10, 0x1a20, 0x05b0, 0x05b0, 0x05b0, + 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x1a30, 0x1a40, 0x05b0, 0x05b0, + 0x05b0, 0x05b0, 0x05b0, 0x1a50, 0x0870, 0x05b0, 0x05b0, 0x05b0, + 0x05b0, 0x1a60, 0x05b0, 0x05b0, 0x06b0, 0x0870, 0x0870, 0x1a70, + 0x0580, 0x1a80, 0x10b0, 0x1a90, 0x1aa0, 0x1ab0, 0x1ac0, 0x1100, + 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x05b0, 0x1ad0, + 0x1ae0, 0x1af0, 0x1610, 0x1b00, 0x1610, 0x1b10, 0x1b20, 0x1b30, + 0x05b0, 0x1b40, 0x05b0, 0x0850, 0x1b50, 0x1b60, 0x1b70, 0x1b80, /* values */ 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0022, 0x0003, 0x0001, 0x0001, 0x0002, 0x0004, 0x0004, @@ -230,18 +230,20 @@ 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0011, 0x0011, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, - 0x0011, 0x0019, 0x0022, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, + 0x0011, 0x0019, 0x0022, 0x0011, 0x0011, 0x0011, 0x0011, 0x001a, 0x0011, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0022, 0x0004, 0x001d, 0x0004, 0x0004, 0x001d, 0x0004, 0x0004, 0x0017, 0x0004, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, - 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, - 0x001d, 0x001d, 0x001d, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, - 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0011, 0x0011, 0x0011, - 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, - 0x001d, 0x001d, 0x001d, 0x001d, 0x0011, 0x0011, 0x001d, 0x001d, + 0x0026, 0x0026, 0x0026, 0x0026, 0x0026, 0x0026, 0x0026, 0x0026, + 0x0026, 0x0026, 0x0026, 0x0026, 0x0026, 0x0026, 0x0026, 0x0026, + 0x0026, 0x0026, 0x0026, 0x0026, 0x0026, 0x0026, 0x0026, 0x0026, + 0x0026, 0x0026, 0x0026, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, + 0x0026, 0x0026, 0x0026, 0x001d, 0x001d, 0x0011, 0x0011, 0x0011, + 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, + 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0011, 0x001d, 0x001d, 0x001d, 0x001b, 0x001b, 0x001b, 0x0019, 0x0019, 0x001d, 0x001d, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0017, 0x0011, 0x0011, 0x0017, 0x0017, @@ -279,6 +281,12 @@ 0x001d, 0x0004, 0x0004, 0x0004, 0x0011, 0x0011, 0x001d, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, + 0x001d, 0x0011, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, + 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0011, 0x0011, 0x0011, + 0x0011, 0x0011, 0x0011, 0x0011, 0x0004, 0x0004, 0x0004, 0x0004, + 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, + 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, + 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0011, 0x0004, 0x0004, 0x0004, 0x0004, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, @@ -325,7 +333,7 @@ 0x0004, 0x0004, 0x0011, 0x0004, 0x0004, 0x0004, 0x0011, 0x0011, 0x001d, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, - 0x0011, 0x001a, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, + 0x001d, 0x001a, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0011, 0x0011, 0x0004, 0x0004, 0x0011, 0x0011, 0x0004, 0x0004, 0x0004, 0x0011, 0x0011, @@ -406,7 +414,7 @@ 0x0023, 0x0023, 0x0023, 0x0023, 0x0023, 0x0011, 0x0023, 0x0011, 0x0023, 0x0023, 0x0023, 0x0023, 0x0023, 0x0023, 0x0011, 0x0011, 0x001c, 0x001c, 0x001c, 0x001c, 0x001c, 0x001c, 0x001c, 0x001c, - 0x001c, 0x001c, 0x0011, 0x0011, 0x0023, 0x0023, 0x0011, 0x0011, + 0x001c, 0x001c, 0x0011, 0x0011, 0x0023, 0x0023, 0x0023, 0x0023, 0x001d, 0x0021, 0x0021, 0x0021, 0x0021, 0x001d, 0x0021, 0x0021, 0x0006, 0x0021, 0x0021, 0x0022, 0x0006, 0x0017, 0x0017, 0x0017, 0x0017, 0x0017, 0x0006, 0x001d, 0x0017, 0x001d, 0x001d, 0x001d, @@ -431,8 +439,8 @@ 0x001c, 0x001c, 0x0022, 0x0022, 0x001d, 0x001d, 0x001d, 0x001d, 0x001c, 0x001c, 0x001c, 0x001c, 0x001c, 0x001c, 0x001c, 0x001c, 0x001c, 0x001c, 0x0023, 0x0023, 0x0023, 0x0023, 0x0023, 0x0023, - 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0011, 0x0011, - 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, + 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0011, 0x001d, + 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x001d, 0x0011, 0x0011, 0x000c, 0x000c, 0x000c, 0x000c, 0x000c, 0x000c, 0x000c, 0x000c, 0x000c, 0x000c, 0x000c, 0x000c, 0x000c, 0x000c, 0x000c, 0x000c, 0x000d, 0x000d, 0x000d, 0x000d, 0x000d, 0x000d, 0x000d, 0x000d, @@ -457,6 +465,8 @@ 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, + 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0011, 0x0011, 0x0011, + 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0022, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, @@ -481,6 +491,8 @@ 0x0017, 0x0017, 0x001d, 0x0004, 0x0004, 0x0004, 0x0006, 0x0011, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0004, 0x001d, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, + 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0011, 0x0011, + 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0011, 0x0011, 0x0011, 0x0011, 0x001d, 0x0011, 0x0011, 0x0011, 0x0017, 0x0017, 0x001c, 0x001c, @@ -516,7 +528,7 @@ 0x0004, 0x0004, 0x0004, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, - 0x0004, 0x0004, 0x0004, 0x0011, 0x0011, 0x0011, 0x001d, 0x001d, + 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x001d, 0x001d, 0x0004, 0x0004, 0x0004, 0x0004, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x001d, 0x001d, 0x001d, 0x001d, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, @@ -529,7 +541,7 @@ 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x001d, 0x001d, 0x001d, 0x001d, 0x0004, 0x001d, 0x001d, - 0x001d, 0x001d, 0x0004, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, + 0x001d, 0x001d, 0x0004, 0x0004, 0x0004, 0x001d, 0x001d, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, @@ -568,7 +580,7 @@ 0x001a, 0x001a, 0x001a, 0x001a, 0x001a, 0x001a, 0x001a, 0x001b, 0x001a, 0x001a, 0x001a, 0x001a, 0x001a, 0x001a, 0x001a, 0x001a, 0x001a, 0x001a, 0x001a, 0x001a, 0x001a, 0x001a, 0x001b, 0x001a, - 0x001a, 0x001a, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, + 0x001a, 0x001a, 0x001a, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0004, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x001d, 0x001d, 0x001d, 0x001b, 0x001d, 0x0024, 0x001d, 0x001d, @@ -609,12 +621,16 @@ 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0024, + 0x001d, 0x001d, 0x0024, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, + 0x001d, 0x001d, 0x001e, 0x001e, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0012, 0x0013, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, - 0x001d, 0x001d, 0x001d, 0x001d, 0x0011, 0x0011, 0x0011, 0x0011, - 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, - 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0011, - 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, + 0x001e, 0x001e, 0x001e, 0x001e, 0x0011, 0x0011, 0x0011, 0x0011, + 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, + 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0011, + 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, + 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, + 0x001d, 0x001d, 0x001d, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, @@ -633,20 +649,32 @@ 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0024, 0x0024, 0x0024, 0x0024, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0024, - 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0024, 0x0024, 0x001d, + 0x001e, 0x001e, 0x001e, 0x001e, 0x001d, 0x0024, 0x0024, 0x001d, 0x001d, 0x0024, 0x001d, 0x001d, 0x001d, 0x001d, 0x0024, 0x0024, - 0x001d, 0x001d, 0x001d, 0x001d, 0x0024, 0x0024, 0x0024, 0x0024, - 0x001d, 0x001d, 0x001d, 0x001d, 0x0024, 0x001d, 0x0024, 0x001d, + 0x001d, 0x001d, 0x001d, 0x001d, 0x001e, 0x001e, 0x0024, 0x0024, + 0x001e, 0x001d, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, + 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, + 0x001d, 0x001e, 0x001e, 0x001e, 0x001d, 0x001d, 0x001d, 0x001d, 0x0024, 0x001d, 0x0024, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0024, 0x0024, 0x001d, 0x0024, 0x0024, 0x0024, 0x001d, 0x0024, - 0x0024, 0x0024, 0x0024, 0x001d, 0x0024, 0x0024, 0x001d, 0x0024, + 0x001e, 0x0024, 0x0024, 0x001d, 0x0024, 0x0024, 0x001d, 0x0024, + 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, + 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001e, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0024, 0x0024, - 0x001d, 0x001d, 0x001d, 0x001d, 0x0024, 0x0024, 0x0024, 0x0024, - 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x001d, 0x0024, - 0x0024, 0x0024, 0x001d, 0x0024, 0x001d, 0x001d, 0x001d, 0x001d, - 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, + 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, + 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001e, 0x001e, 0x001e, + 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, + 0x001e, 0x0024, 0x0024, 0x0024, 0x0024, 0x001e, 0x001d, 0x001e, + 0x001e, 0x001e, 0x0024, 0x001e, 0x001e, 0x0024, 0x0024, 0x0024, + 0x001e, 0x001e, 0x0024, 0x0024, 0x001e, 0x0024, 0x0024, 0x001e, + 0x001e, 0x001e, 0x001d, 0x0024, 0x001d, 0x001d, 0x001d, 0x001d, + 0x0024, 0x0024, 0x001e, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, + 0x0024, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x0024, 0x001e, + 0x001e, 0x001e, 0x001e, 0x0024, 0x0024, 0x001e, 0x001e, 0x001e, + 0x0011, 0x001e, 0x001e, 0x001e, 0x001e, 0x001d, 0x001d, 0x001d, + 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0024, 0x001d, 0x001d, 0x001d, 0x0015, 0x0015, 0x0015, 0x0015, 0x001d, 0x001d, 0x001d, 0x0017, 0x0017, 0x001d, 0x001d, 0x001d, 0x001d, @@ -656,7 +684,7 @@ 0x0024, 0x0024, 0x0024, 0x0024, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0012, 0x0013, 0x001d, - 0x001d, 0x001d, 0x001d, 0x0011, 0x001d, 0x0011, 0x001d, 0x001d, + 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0012, 0x0013, 0x0012, 0x0013, 0x0012, 0x0013, 0x0012, 0x0013, 0x0012, 0x0013, 0x001d, 0x001d, 0x001d, 0x0012, 0x0013, 0x0012, 0x0013, 0x0012, @@ -671,9 +699,9 @@ 0x0024, 0x0024, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0004, - 0x0004, 0x0004, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, + 0x0004, 0x0004, 0x001d, 0x001d, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0017, 0x0022, 0x0022, 0x0022, 0x001d, 0x0017, 0x0022, - 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0011, 0x0011, + 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x001d, 0x0022, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0004, @@ -685,14 +713,12 @@ 0x0012, 0x0022, 0x001d, 0x001d, 0x0015, 0x0015, 0x001d, 0x001d, 0x0015, 0x0015, 0x0012, 0x0013, 0x0012, 0x0013, 0x0012, 0x0013, 0x0012, 0x0013, 0x0022, 0x0022, 0x0022, 0x0022, 0x0017, 0x001d, - 0x0022, 0x0022, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, - 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, + 0x0022, 0x0022, 0x001d, 0x0022, 0x0022, 0x001d, 0x001d, 0x001d, + 0x001d, 0x001d, 0x0025, 0x0025, 0x0011, 0x0011, 0x0011, 0x0011, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x0011, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, - 0x001e, 0x001e, 0x001e, 0x001e, 0x0011, 0x0011, 0x0011, 0x0011, - 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, @@ -705,18 +731,18 @@ 0x001e, 0x001e, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x0016, 0x0016, 0x001e, 0x001e, 0x001e, - 0x0011, 0x0016, 0x001e, 0x0016, 0x001e, 0x0016, 0x001e, 0x0016, - 0x001e, 0x0016, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, - 0x001e, 0x001e, 0x001e, 0x0016, 0x001e, 0x001e, 0x001e, 0x001e, - 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, - 0x001e, 0x001e, 0x001e, 0x0016, 0x001e, 0x0016, 0x001e, 0x0016, - 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x0016, 0x001e, - 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x0016, 0x0016, 0x0011, + 0x0011, 0x0027, 0x001e, 0x0027, 0x001e, 0x0027, 0x001e, 0x0027, + 0x001e, 0x0027, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, + 0x001e, 0x001e, 0x001e, 0x0027, 0x001e, 0x001e, 0x001e, 0x001e, + 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, + 0x001e, 0x001e, 0x001e, 0x0027, 0x001e, 0x0027, 0x001e, 0x0027, + 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x0027, 0x001e, + 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x0027, 0x0027, 0x0011, 0x0011, 0x0004, 0x0004, 0x0016, 0x0016, 0x0016, 0x0016, 0x001e, - 0x0016, 0x0016, 0x001e, 0x0016, 0x001e, 0x0016, 0x001e, 0x0016, - 0x001e, 0x0016, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, - 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x0016, 0x0016, 0x001e, - 0x001e, 0x001e, 0x001e, 0x0016, 0x0016, 0x0016, 0x0016, 0x001e, + 0x0016, 0x0027, 0x001e, 0x0027, 0x001e, 0x0027, 0x001e, 0x0027, + 0x001e, 0x0027, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, + 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x0027, 0x0027, 0x001e, + 0x001e, 0x001e, 0x001e, 0x0016, 0x0027, 0x0016, 0x0016, 0x001e, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, @@ -727,8 +753,8 @@ 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x0011, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, - 0x0016, 0x0016, 0x0016, 0x0016, 0x0016, 0x0016, 0x0016, 0x0016, - 0x0016, 0x0016, 0x0016, 0x0016, 0x0016, 0x0016, 0x0016, 0x0016, + 0x0027, 0x0027, 0x0027, 0x0027, 0x0027, 0x0027, 0x0027, 0x0027, + 0x0027, 0x0027, 0x0027, 0x0027, 0x0027, 0x0027, 0x0027, 0x0027, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x0024, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x0016, 0x001e, 0x001e, @@ -741,14 +767,14 @@ 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0022, 0x0017, 0x0022, 0x001c, 0x001c, 0x001c, 0x001c, 0x001c, 0x001c, 0x001c, 0x001c, 0x001c, 0x001c, 0x001d, 0x001d, 0x0011, 0x0011, 0x0011, 0x0011, - 0x0004, 0x0004, 0x0004, 0x001d, 0x0011, 0x0011, 0x0011, 0x0011, - 0x0011, 0x0011, 0x0011, 0x0011, 0x0004, 0x0004, 0x001d, 0x001d, + 0x0004, 0x0004, 0x0004, 0x001d, 0x0004, 0x0004, 0x0004, 0x0004, + 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x001d, 0x001d, + 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, + 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0004, 0x0004, 0x0004, 0x001d, 0x0022, 0x0022, 0x0022, 0x0022, 0x0022, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, - 0x001d, 0x001d, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, - 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, - 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, - 0x0011, 0x0011, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, + 0x001d, 0x001d, 0x001d, 0x001d, 0x0011, 0x0011, 0x0011, 0x0011, + 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x001d, 0x001d, 0x0004, 0x001d, 0x001d, 0x001d, 0x0004, 0x001d, 0x001d, 0x001d, 0x001d, 0x0004, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, @@ -787,6 +813,8 @@ 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0023, 0x0023, 0x0023, 0x0023, 0x0023, + 0x0022, 0x0022, 0x001d, 0x001d, 0x001d, 0x0004, 0x0004, 0x0011, + 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0011, 0x0011, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0011, 0x0011, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0011, @@ -812,11 +840,15 @@ 0x0005, 0x0005, 0x0005, 0x0005, 0x0005, 0x0005, 0x0005, 0x0005, 0x0005, 0x0005, 0x0005, 0x0005, 0x0005, 0x0005, 0x0005, 0x0005, 0x0011, 0x0011, 0x0011, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, - 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x001d, 0x0004, 0x001d, - 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0011, - 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0011, 0x001d, 0x0011, - 0x001d, 0x001d, 0x0011, 0x001d, 0x001d, 0x0011, 0x001d, 0x001d, - 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, + 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0026, 0x0004, 0x0026, + 0x0026, 0x0026, 0x0026, 0x0026, 0x0026, 0x0026, 0x0026, 0x0026, + 0x0026, 0x001d, 0x0026, 0x0026, 0x0026, 0x0026, 0x0026, 0x0026, + 0x0026, 0x0026, 0x0026, 0x0026, 0x0026, 0x0026, 0x0026, 0x0011, + 0x0026, 0x0026, 0x0026, 0x0026, 0x0026, 0x0011, 0x0026, 0x0011, + 0x0026, 0x0026, 0x0011, 0x0026, 0x0026, 0x0011, 0x0026, 0x0026, + 0x0026, 0x0026, 0x0026, 0x0026, 0x0026, 0x0026, 0x0026, 0x0026, + 0x001d, 0x001d, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, + 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x0011, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, @@ -845,9 +877,9 @@ 0x001e, 0x001e, 0x001e, 0x0012, 0x001e, 0x0013, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x001e, 0x0012, 0x001e, 0x0013, 0x001e, 0x0012, - 0x0013, 0x0013, 0x0012, 0x0013, 0x0013, 0x0016, 0x001d, 0x0016, - 0x0016, 0x0016, 0x0016, 0x0016, 0x0016, 0x0016, 0x0016, 0x0016, - 0x0016, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, + 0x0013, 0x0013, 0x0012, 0x0013, 0x0013, 0x0016, 0x001d, 0x0027, + 0x0027, 0x0027, 0x0027, 0x0027, 0x0027, 0x0027, 0x0027, 0x0027, + 0x0027, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x001d, 0x0016, 0x0016, Modified: trunk/reactos/dll/win32/usp10/mirror.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/usp10/mirror.c?r…
============================================================================== --- trunk/reactos/dll/win32/usp10/mirror.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/usp10/mirror.c [iso-8859-1] Sat Sep 28 15:11:02 2013 @@ -1,5 +1,5 @@ /* Unicode BiDi mirroring */ -/* generated from
http://www.unicode.org/Public/6.0.0/ucd/BidiMirroring.txt
*/ +/* generated from
http://www.unicode.org/Public/6.2.0/ucd/BidiMirroring.txt
*/ /* DO NOT EDIT!! */ #include <wine/unicode.h> @@ -244,7 +244,7 @@ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0xffff, 0x0001, 0xffff, 0x0000, - 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0001, 0xffff, 0x0000, 0x0002, 0x0000, 0xfffe, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0xffff, 0x0000, 0x0000, 0x0000, 0x0001, 0xffff, 0x0001, 0xffff, 0x0001, 0xffff, Modified: trunk/reactos/dll/win32/usp10/opentype.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/usp10/opentype.c…
============================================================================== --- trunk/reactos/dll/win32/usp10/opentype.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/usp10/opentype.c [iso-8859-1] Sat Sep 28 15:11:02 2013 @@ -478,6 +478,12 @@ WORD PosCount; GPOS_PosLookupRecord PosLookupRecord[1]; } GPOS_ChainContextPosFormat3_4; + +typedef struct { + WORD PosFormat; + WORD ExtensionLookupType; + DWORD ExtensionOffset; +} GPOS_ExtensionPosFormat1; /********** * CMAP @@ -1166,6 +1172,25 @@ if (ValueFormat & 0xFF00) FIXME("Unhandled Value Format %x\n",ValueFormat&0xFF00); } +static const BYTE *GPOS_get_subtable(const OT_LookupTable *look, int index) +{ + int offset = GET_BE_WORD(look->SubTable[index]); + + if (GET_BE_WORD(look->LookupType) == 9) + { + const GPOS_ExtensionPosFormat1 *ext = (const GPOS_ExtensionPosFormat1 *)((const BYTE *)look + offset); + if (GET_BE_WORD(ext->PosFormat) == 1) + { + offset += GET_BE_DWORD(ext->ExtensionOffset); + } + else + { + FIXME("Unhandled Extension Positioning Format %i\n",GET_BE_WORD(ext->PosFormat)); + } + } + return (const BYTE *)look + offset; +} + static VOID GPOS_apply_SingleAdjustment(const OT_LookupTable *look, const SCRIPT_ANALYSIS *analysis, const WORD *glyphs, INT glyph_index, INT glyph_count, INT ppem, LPPOINT ptAdjust, LPPOINT ptAdvance) { @@ -1175,9 +1200,8 @@ for (j = 0; j < GET_BE_WORD(look->SubTableCount); j++) { - const GPOS_SinglePosFormat1 *spf1; - WORD offset = GET_BE_WORD(look->SubTable[j]); - spf1 = (const GPOS_SinglePosFormat1*)((const BYTE*)look+offset); + const GPOS_SinglePosFormat1 *spf1 = (const GPOS_SinglePosFormat1*)GPOS_get_subtable(look, j); + WORD offset; if (GET_BE_WORD(spf1->PosFormat) == 1) { offset = GET_BE_WORD(spf1->Coverage); @@ -1253,9 +1277,8 @@ for (j = 0; j < GET_BE_WORD(look->SubTableCount); j++) { - const GPOS_PairPosFormat1 *ppf1; - WORD offset = GET_BE_WORD(look->SubTable[j]); - ppf1 = (const GPOS_PairPosFormat1*)((const BYTE*)look+offset); + const GPOS_PairPosFormat1 *ppf1 = (const GPOS_PairPosFormat1*)GPOS_get_subtable(look, j); + WORD offset; if (GET_BE_WORD(ppf1->PosFormat) == 1) { int index; @@ -1292,7 +1315,7 @@ } else if (GET_BE_WORD(ppf1->PosFormat) == 2) { - const GPOS_PairPosFormat2 *ppf2 = (const GPOS_PairPosFormat2*)((const BYTE*)look + offset); + const GPOS_PairPosFormat2 *ppf2 = (const GPOS_PairPosFormat2*)ppf1; int index; WORD ValueFormat1 = GET_BE_WORD( ppf2->ValueFormat1 ); WORD ValueFormat2 = GET_BE_WORD( ppf2->ValueFormat2 ); @@ -1339,13 +1362,11 @@ for (j = 0; j < GET_BE_WORD(look->SubTableCount); j++) { - const GPOS_CursivePosFormat1 *cpf1; - WORD offset = GET_BE_WORD(look->SubTable[j]); - cpf1 = (const GPOS_CursivePosFormat1*)((const BYTE*)look+offset); + const GPOS_CursivePosFormat1 *cpf1 = (const GPOS_CursivePosFormat1 *)GPOS_get_subtable(look, j); if (GET_BE_WORD(cpf1->PosFormat) == 1) { int index_exit, index_entry; - offset = GET_BE_WORD( cpf1->Coverage ); + WORD offset = GET_BE_WORD( cpf1->Coverage ); index_exit = GSUB_is_glyph_covered((const BYTE*)cpf1+offset, glyphs[glyph_index]); if (index_exit != -1 && cpf1->EntryExitRecord[index_exit].ExitAnchor!= 0) { @@ -1389,10 +1410,7 @@ for (j = 0; j < GET_BE_WORD(look->SubTableCount); j++) { - int offset; - const GPOS_MarkBasePosFormat1 *mbpf1; - offset = GET_BE_WORD(look->SubTable[j]); - mbpf1 = (const GPOS_MarkBasePosFormat1*)((const BYTE*)look+offset); + const GPOS_MarkBasePosFormat1 *mbpf1 = (const GPOS_MarkBasePosFormat1 *)GPOS_get_subtable(look, j); if (GET_BE_WORD(mbpf1->PosFormat) == 1) { int offset = GET_BE_WORD(mbpf1->MarkCoverage); @@ -1466,10 +1484,7 @@ for (j = 0; j < GET_BE_WORD(look->SubTableCount); j++) { - int offset; - const GPOS_MarkLigPosFormat1 *mlpf1; - offset = GET_BE_WORD(look->SubTable[j]); - mlpf1 = (const GPOS_MarkLigPosFormat1*)((const BYTE*)look+offset); + const GPOS_MarkLigPosFormat1 *mlpf1 = (const GPOS_MarkLigPosFormat1 *)GPOS_get_subtable(look, j); if (GET_BE_WORD(mlpf1->PosFormat) == 1) { int offset = GET_BE_WORD(mlpf1->MarkCoverage); @@ -1560,10 +1575,7 @@ for (j = 0; j < GET_BE_WORD(look->SubTableCount); j++) { - int offset; - const GPOS_MarkMarkPosFormat1 *mmpf1; - offset = GET_BE_WORD(look->SubTable[j]); - mmpf1 = (const GPOS_MarkMarkPosFormat1*)((const BYTE*)look+offset); + const GPOS_MarkMarkPosFormat1 *mmpf1 = (const GPOS_MarkMarkPosFormat1 *)GPOS_get_subtable(look, j); if (GET_BE_WORD(mmpf1->PosFormat) == 1) { int offset = GET_BE_WORD(mmpf1->Mark1Coverage); @@ -1590,7 +1602,7 @@ ma = (const GPOS_MarkArray*)((const BYTE*)mmpf1 + offset); if (mark_index > GET_BE_WORD(ma->MarkCount)) { - ERR("Mark index exeeded mark count\n"); + ERR("Mark index exceeded mark count\n"); return FALSE; } mr = &ma->MarkRecord[mark_index]; @@ -1631,12 +1643,9 @@ for (j = 0; j < GET_BE_WORD(look->SubTableCount); j++) { int offset; - const GPOS_ChainContextPosFormat3_1 *ccpf3; + const GPOS_ChainContextPosFormat3_1 *ccpf3 = (GPOS_ChainContextPosFormat3_1 *)GPOS_get_subtable(look, j); int dirLookahead = write_dir; int dirBacktrack = -1 * write_dir; - - offset = GET_BE_WORD(look->SubTable[j]); - ccpf3 = (const GPOS_ChainContextPosFormat3_1*)((const BYTE*)look+offset); if (GET_BE_WORD(ccpf3->PosFormat) == 1) { @@ -1723,11 +1732,33 @@ int offset; const OT_LookupTable *look; int ppem = lpotm->otmTextMetrics.tmAscent + lpotm->otmTextMetrics.tmDescent - lpotm->otmTextMetrics.tmInternalLeading; + WORD type; offset = GET_BE_WORD(lookup->Lookup[lookup_index]); look = (const OT_LookupTable*)((const BYTE*)lookup + offset); - TRACE("type %i, flag %x, subtables %i\n",GET_BE_WORD(look->LookupType),GET_BE_WORD(look->LookupFlag),GET_BE_WORD(look->SubTableCount)); - switch(GET_BE_WORD(look->LookupType)) + type = GET_BE_WORD(look->LookupType); + TRACE("type %i, flag %x, subtables %i\n",type,GET_BE_WORD(look->LookupFlag),GET_BE_WORD(look->SubTableCount)); + if (type == 9) + { + if (GET_BE_WORD(look->SubTableCount)) + { + const GPOS_ExtensionPosFormat1 *ext = (const GPOS_ExtensionPosFormat1 *)((const BYTE *)look + GET_BE_WORD(look->SubTable[0])); + if (GET_BE_WORD(ext->PosFormat) == 1) + { + type = GET_BE_WORD(ext->ExtensionLookupType); + TRACE("extension type %i\n",type); + } + else + { + FIXME("Unhandled Extension Positioning Format %i\n",GET_BE_WORD(ext->PosFormat)); + } + } + else + { + WARN("lookup type is Extension Positioning but no extension subtable exists\n"); + } + } + switch (type) { case 1: { @@ -1849,7 +1880,7 @@ return GPOS_apply_ChainContextPos(psc, lpotm, lplogfont, analysis, piAdvance, lookup, look, glyphs, glyph_index, glyph_count, ppem, pGoffset); } default: - FIXME("We do not handle SubType %i\n",GET_BE_WORD(look->LookupType)); + FIXME("We do not handle SubType %i\n",type); } return glyph_index+1; } Modified: trunk/reactos/dll/win32/usp10/shaping.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/usp10/shaping.c?…
============================================================================== --- trunk/reactos/dll/win32/usp10/shaping.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/usp10/shaping.c [iso-8859-1] Sat Sep 28 15:11:02 2013 @@ -1,10 +1,10 @@ /* Unicode Arabic shaping */ -/* generated from
http://www.unicode.org/Public/6.0.0/ucd/ArabicShaping.txt
*/ +/* generated from
http://www.unicode.org/Public/6.2.0/ucd/ArabicShaping.txt
*/ /* DO NOT EDIT!! */ //#include "wine/unicode.h" -const unsigned short wine_shaping_table[2656] = +const unsigned short wine_shaping_table[2752] = { /* level 1 offsets */ 0x0100, 0x0110, 0x0110, 0x0120, 0x0130, 0x0140, 0x0150, 0x0160, @@ -54,64 +54,64 @@ 0x0410, 0x0420, 0x0430, 0x0440, 0x0450, 0x0460, 0x0470, 0x0480, 0x0490, 0x04a0, 0x04b0, 0x0360, 0x04c0, 0x04d0, 0x04e0, 0x04f0, 0x0340, 0x0340, 0x0500, 0x0510, 0x0520, 0x0530, 0x0540, 0x0550, - 0x0340, 0x0560, 0x0570, 0x0340, 0x0340, 0x0580, 0x0340, 0x0340, - 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, - 0x0590, 0x0340, 0x0340, 0x05a0, 0x05b0, 0x05c0, 0x05d0, 0x0340, - 0x05e0, 0x0340, 0x0340, 0x05f0, 0x0600, 0x0340, 0x05d0, 0x0340, - 0x0610, 0x0340, 0x0340, 0x05f0, 0x0620, 0x05e0, 0x0340, 0x0630, - 0x0610, 0x0340, 0x0340, 0x05f0, 0x0640, 0x0340, 0x05d0, 0x0340, - 0x05e0, 0x0340, 0x0340, 0x0650, 0x0600, 0x0660, 0x05d0, 0x0340, - 0x0670, 0x0340, 0x0340, 0x0340, 0x0680, 0x0340, 0x0340, 0x0340, - 0x0340, 0x0340, 0x0340, 0x0690, 0x06a0, 0x06b0, 0x05d0, 0x0340, - 0x0340, 0x0340, 0x0340, 0x0650, 0x06c0, 0x0340, 0x05d0, 0x0340, - 0x0340, 0x0340, 0x0340, 0x0340, 0x0600, 0x0340, 0x05d0, 0x0340, - 0x0340, 0x0340, 0x0340, 0x0340, 0x06d0, 0x06e0, 0x0340, 0x0340, - 0x0340, 0x0340, 0x0340, 0x06f0, 0x0700, 0x0340, 0x0340, 0x0340, - 0x0340, 0x0340, 0x0340, 0x0710, 0x0720, 0x0340, 0x0340, 0x0340, - 0x0340, 0x0730, 0x0340, 0x0740, 0x0340, 0x0340, 0x0340, 0x0750, - 0x0760, 0x0770, 0x0360, 0x0780, 0x0660, 0x0340, 0x0340, 0x0340, - 0x0340, 0x0340, 0x0790, 0x07a0, 0x0340, 0x07b0, 0x0510, 0x07c0, - 0x07d0, 0x0350, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, - 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0790, 0x0340, 0x0340, - 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, - 0x0340, 0x07e0, 0x0340, 0x07e0, 0x0340, 0x05d0, 0x0340, 0x05d0, - 0x0340, 0x0340, 0x0340, 0x07f0, 0x0800, 0x0810, 0x0340, 0x0340, - 0x0820, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, - 0x0340, 0x0340, 0x0830, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, - 0x0340, 0x0340, 0x0840, 0x0850, 0x0340, 0x0340, 0x0340, 0x0340, - 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, - 0x0340, 0x0860, 0x0340, 0x0340, 0x0340, 0x0870, 0x0880, 0x0890, - 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, - 0x08a0, 0x0340, 0x0340, 0x08b0, 0x0670, 0x0340, 0x08c0, 0x08a0, - 0x08d0, 0x0340, 0x08e0, 0x0340, 0x0340, 0x0340, 0x08f0, 0x08d0, - 0x0340, 0x0340, 0x0900, 0x0910, 0x0340, 0x0340, 0x0340, 0x0340, - 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0920, 0x0930, 0x0340, - 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, - 0x0340, 0x0340, 0x0340, 0x0340, 0x0360, 0x0360, 0x0940, 0x0900, - 0x0950, 0x0340, 0x0960, 0x0340, 0x0340, 0x0340, 0x0970, 0x0340, + 0x0340, 0x0560, 0x0570, 0x0340, 0x0580, 0x0590, 0x0340, 0x0340, + 0x0340, 0x0340, 0x05a0, 0x0340, 0x0340, 0x0340, 0x05b0, 0x05c0, + 0x05d0, 0x0340, 0x0340, 0x05e0, 0x05f0, 0x0600, 0x0610, 0x0340, + 0x0620, 0x0340, 0x0340, 0x0630, 0x0640, 0x0340, 0x0610, 0x0340, + 0x0650, 0x0340, 0x0340, 0x0630, 0x0660, 0x0620, 0x0340, 0x0670, + 0x0650, 0x0340, 0x0340, 0x0630, 0x0680, 0x0340, 0x0610, 0x0340, + 0x0620, 0x0340, 0x0340, 0x0690, 0x0640, 0x06a0, 0x0610, 0x0340, + 0x06b0, 0x0340, 0x0340, 0x0340, 0x06c0, 0x0340, 0x0340, 0x0340, + 0x0340, 0x0340, 0x0340, 0x06d0, 0x06e0, 0x06f0, 0x0610, 0x0340, + 0x0340, 0x0340, 0x0340, 0x0690, 0x0700, 0x0340, 0x0610, 0x0340, + 0x0340, 0x0340, 0x0340, 0x0340, 0x0640, 0x0340, 0x0610, 0x0340, + 0x0340, 0x0340, 0x0340, 0x0340, 0x0710, 0x0720, 0x0340, 0x0340, + 0x0340, 0x0340, 0x0340, 0x0730, 0x0740, 0x0340, 0x0340, 0x0340, + 0x0340, 0x0340, 0x0340, 0x0750, 0x0760, 0x0340, 0x0340, 0x0340, + 0x0340, 0x0770, 0x0340, 0x0780, 0x0340, 0x0340, 0x0340, 0x0790, + 0x07a0, 0x07b0, 0x0360, 0x07c0, 0x06a0, 0x0340, 0x0340, 0x0340, + 0x0340, 0x0340, 0x07d0, 0x07e0, 0x0340, 0x07f0, 0x0510, 0x0800, + 0x0810, 0x0350, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, + 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x07d0, 0x0340, 0x0340, + 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, + 0x0340, 0x0820, 0x0340, 0x0820, 0x0340, 0x0610, 0x0340, 0x0610, + 0x0340, 0x0340, 0x0340, 0x0830, 0x0840, 0x0850, 0x0340, 0x0340, + 0x0860, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, + 0x0340, 0x0340, 0x0870, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, + 0x0340, 0x0340, 0x0880, 0x0890, 0x0340, 0x0340, 0x0340, 0x0340, + 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, + 0x0340, 0x08a0, 0x0340, 0x0340, 0x0340, 0x08b0, 0x08c0, 0x08d0, + 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, + 0x08e0, 0x0340, 0x0340, 0x08f0, 0x06b0, 0x0340, 0x0900, 0x08e0, + 0x0910, 0x0340, 0x0920, 0x0340, 0x0340, 0x0340, 0x0930, 0x0910, + 0x0340, 0x0340, 0x0940, 0x0950, 0x0340, 0x0340, 0x0340, 0x0340, + 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0960, 0x0970, 0x0980, + 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, + 0x0340, 0x0340, 0x0340, 0x0340, 0x0360, 0x0360, 0x0990, 0x0940, + 0x09a0, 0x0340, 0x09b0, 0x0340, 0x0340, 0x0340, 0x09c0, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0360, 0x0360, 0x0510, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, - 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0490, 0x08d0, + 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0490, 0x0910, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0490, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0360, 0x0360, - 0x0340, 0x0340, 0x0980, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, - 0x0340, 0x0990, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, - 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0490, 0x09a0, - 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x08d0, - 0x09b0, 0x0340, 0x06b0, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, - 0x0340, 0x0340, 0x0340, 0x0340, 0x09c0, 0x0340, 0x0360, 0x08d0, - 0x0340, 0x0340, 0x09d0, 0x0340, 0x09e0, 0x08d0, 0x0340, 0x0340, - 0x0590, 0x0340, 0x0340, 0x09f0, 0x0340, 0x0340, 0x0340, 0x0340, - 0x0340, 0x0340, 0x0a00, 0x0a10, 0x0a20, 0x0340, 0x0340, 0x0340, - 0x0340, 0x0340, 0x0340, 0x0a30, 0x05e0, 0x0340, 0x0340, 0x0340, - 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, - 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0a40, 0x0340, - 0x0340, 0x0a50, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, - 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, - 0x0360, 0x0340, 0x0940, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, + 0x0340, 0x0340, 0x09d0, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, + 0x0340, 0x09e0, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, + 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0490, 0x09f0, + 0x0340, 0x0490, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0910, + 0x0a00, 0x0340, 0x06f0, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, + 0x0340, 0x0340, 0x0340, 0x0340, 0x0980, 0x0340, 0x0360, 0x0910, + 0x0340, 0x0340, 0x0a10, 0x0340, 0x0a20, 0x0910, 0x0340, 0x0340, + 0x05d0, 0x0340, 0x0340, 0x0a30, 0x0340, 0x0340, 0x0340, 0x0340, + 0x0340, 0x0340, 0x0a40, 0x0a50, 0x0a60, 0x0340, 0x0340, 0x0340, + 0x0340, 0x0340, 0x0340, 0x0a70, 0x0620, 0x0340, 0x0a80, 0x06a0, + 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, + 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0a90, 0x0340, + 0x0340, 0x0aa0, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, + 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, + 0x0360, 0x0340, 0x0990, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0490, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, - 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0580, + 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0340, 0x0ab0, /* values */ 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, @@ -185,8 +185,16 @@ 0x0001, 0x0001, 0x0000, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0000, 0x0001, 0x0001, 0x0001, 0x0000, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0000, 0x0000, - 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0002, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0002, 0x0004, + 0x0004, 0x0002, 0x0004, 0x0004, 0x0004, 0x0004, 0x0004, 0x0002, + 0x0004, 0x0004, 0x0004, 0x0004, 0x0002, 0x0004, 0x0000, 0x0000, 0x0000, 0x0001, 0x0001, 0x0001, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0404, 0x0000, 0x0604, 0x0b04, 0x0f04, 0x1004, 0x1204, 0x1304, + 0x0104, 0x0104, 0x0802, 0x0302, 0x3402, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0x0001, 0x0001, 0x0001, + 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, + 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, + 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0000, 0x0001, 0x0001, 0x0001, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, @@ -294,7 +302,7 @@ 0x0001, 0x0001, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0x0001, 0x0001, 0x0001, 0x0000, 0x0000, - 0x0001, 0x0001, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0001, 0x0001, 0x0000, 0x0001, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0x0000, 0x0001, 0x0001, 0x0000, 0x0000, 0x0000, 0x0001, 0x0000, 0x0001, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, @@ -305,6 +313,8 @@ 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0000, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, @@ -314,15 +324,13 @@ 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, - 0x0000, 0x0000, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, + 0x0000, 0x0000, 0x0001, 0x0001, 0x0001, 0x0001, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0x0001, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, - 0x0001, 0x0001, 0x0001, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, - 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0x0001, 0x0000, 0x0000, + 0x0001, 0x0001, 0x0001, 0x0000, 0x0001, 0x0001, 0x0001, 0x0001, + 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0x0000, 0x0000, 0x0000, 0x0001, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0x0000, 0x0000, 0x0000, 0x0000, - 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0x0000, 0x0000, 0x0000, - 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0001, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, @@ -337,10 +345,14 @@ 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0x0000, 0x0000, 0x0000, 0x0001, 0x0000, 0x0001, 0x0001, 0x0001, 0x0000, 0x0000, 0x0001, 0x0001, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0x0001, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0x0001, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0x0000, 0x0000, 0x0001, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, - 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0x0000 + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0001, 0x0000, + 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, + 0x0000, 0x0001, 0x0001, 0x0001, 0x0000, 0x0000, 0x0000, 0x0000 }; const unsigned short wine_shaping_forms[256][4] = Modified: trunk/reactos/dll/win32/usp10/usp10.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/usp10/usp10.c?re…
============================================================================== --- trunk/reactos/dll/win32/usp10/usp10.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/usp10/usp10.c [iso-8859-1] Sat Sep 28 15:11:02 2013 @@ -1341,7 +1341,7 @@ if (original == Script_Punctuation2) break; } - if (scriptInformation[scripts[j]].props.fComplex || asian) + if (j >= 0 && (scriptInformation[scripts[j]].props.fComplex || asian)) scripts[i] = scripts[j]; } } Modified: trunk/reactos/media/doc/README.WINE URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/media/doc/README.WINE?rev=…
============================================================================== --- trunk/reactos/media/doc/README.WINE [iso-8859-1] (original) +++ trunk/reactos/media/doc/README.WINE [iso-8859-1] Sat Sep 28 15:11:02 2013 @@ -193,7 +193,7 @@ reactos/dll/win32/updspapi # Synced to Wine-1.5.4 reactos/dll/win32/url # Synced to Wine-1.5.19 reactos/dll/win32/urlmon # Synced to Wine-1.7.1 -reactos/dll/win32/usp10 # Synced to Wine-1.5.26 +reactos/dll/win32/usp10 # Synced to Wine-1.7.1 reactos/dll/win32/uxtheme # Forked reactos/dll/win32/vbscript # Synced to Wine-1.5.26 reactos/dll/win32/version # Autosync
11 years, 2 months
1
0
0
0
[akhaldi] 60417: [URLMON_WINETEST] * Sync with Wine 1.7.1. CORE-7469
by akhaldi@svn.reactos.org
Author: akhaldi Date: Sat Sep 28 15:09:44 2013 New Revision: 60417 URL:
http://svn.reactos.org/svn/reactos?rev=60417&view=rev
Log: [URLMON_WINETEST] * Sync with Wine 1.7.1. CORE-7469 Modified: trunk/rostests/winetests/urlmon/CMakeLists.txt trunk/rostests/winetests/urlmon/generated.c trunk/rostests/winetests/urlmon/misc.c trunk/rostests/winetests/urlmon/protocol.c trunk/rostests/winetests/urlmon/sec_mgr.c trunk/rostests/winetests/urlmon/uri.c trunk/rostests/winetests/urlmon/url.c Modified: trunk/rostests/winetests/urlmon/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/urlmon/CMakeLis…
============================================================================== --- trunk/rostests/winetests/urlmon/CMakeLists.txt [iso-8859-1] (original) +++ trunk/rostests/winetests/urlmon/CMakeLists.txt [iso-8859-1] Sat Sep 28 15:09:44 2013 @@ -1,7 +1,3 @@ - -remove_definitions(-DWINVER=0x502 -D_WIN32_IE=0x600 -D_WIN32_WINNT=0x502) - -add_definitions(-D__ROS_LONG64__) list(APPEND SOURCE generated.c @@ -14,7 +10,7 @@ testlist.c) add_executable(urlmon_winetest ${SOURCE}) -target_link_libraries(urlmon_winetest wine uuid) +target_link_libraries(urlmon_winetest uuid) set_module_type(urlmon_winetest win32cui) -add_importlibs(urlmon_winetest urlmon wininet ole32 oleaut32 user32 advapi32 msvcrt kernel32 ntdll) +add_importlibs(urlmon_winetest urlmon wininet ole32 oleaut32 user32 advapi32 msvcrt kernel32) add_cd_file(TARGET urlmon_winetest DESTINATION reactos/bin FOR all) Modified: trunk/rostests/winetests/urlmon/generated.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/urlmon/generate…
============================================================================== --- trunk/rostests/winetests/urlmon/generated.c [iso-8859-1] (original) +++ trunk/rostests/winetests/urlmon/generated.c [iso-8859-1] Sat Sep 28 15:09:44 2013 @@ -9,9 +9,11 @@ #define _INC_WINDOWS #define COM_NO_WINDOWS_H +#ifndef __REACTOS__ #define WINVER 0x0501 #define _WIN32_IE 0x0501 #define _WIN32_WINNT 0x0501 +#endif #define WINE_NOWINSOCK Modified: trunk/rostests/winetests/urlmon/misc.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/urlmon/misc.c?r…
============================================================================== --- trunk/rostests/winetests/urlmon/misc.c [iso-8859-1] (original) +++ trunk/rostests/winetests/urlmon/misc.c [iso-8859-1] Sat Sep 28 15:09:44 2013 @@ -31,6 +31,7 @@ //#include "windef.h" //#include "winbase.h" #include <winreg.h> +#include <winnls.h> #include <ole2.h> //#include "urlmon.h" @@ -84,6 +85,33 @@ static HRESULT (WINAPI *pCoInternetIsFeatureEnabled)(INTERNETFEATURELIST,DWORD); static HRESULT (WINAPI *pCoInternetSetFeatureEnabled)(INTERNETFEATURELIST,DWORD,BOOL); static HRESULT (WINAPI *pIEInstallScope)(DWORD*); + +static int strcmp_wa(const WCHAR *strw, const char *stra) +{ + WCHAR buf[512]; + MultiByteToWideChar(CP_ACP, 0, stra, -1, buf, sizeof(buf)/sizeof(WCHAR)); + return lstrcmpW(strw, buf); +} + +static void heap_free(void *mem) +{ + HeapFree(GetProcessHeap(), 0, mem); +} + +static WCHAR *a2w(const char *str) +{ + WCHAR *ret; + int len; + + if(!str) + return NULL; + + len = MultiByteToWideChar(CP_ACP, 0, str, -1, NULL, 0); + ret = HeapAlloc(GetProcessHeap(), 0, len*sizeof(WCHAR)); + MultiByteToWideChar(CP_ACP, 0, str, -1, ret, len); + + return ret; +} static void test_CreateFormatEnum(void) { @@ -442,42 +470,14 @@ } } -static const WCHAR mimeTextHtml[] = {'t','e','x','t','/','h','t','m','l',0}; -static const WCHAR mimeTextPlain[] = {'t','e','x','t','/','p','l','a','i','n',0}; -static const WCHAR mimeTextRichtext[] = {'t','e','x','t','/','r','i','c','h','t','e','x','t',0}; -static const WCHAR mimeTextXml[] = {'t','e','x','t','/','x','m','l',0}; -static const WCHAR mimeAppOctetStream[] = {'a','p','p','l','i','c','a','t','i','o','n','/', - 'o','c','t','e','t','-','s','t','r','e','a','m',0}; -static const WCHAR mimeImagePjpeg[] = {'i','m','a','g','e','/','p','j','p','e','g',0}; -static const WCHAR mimeImageGif[] = {'i','m','a','g','e','/','g','i','f',0}; -static const WCHAR mimeImageBmp[] = {'i','m','a','g','e','/','b','m','p',0}; -static const WCHAR mimeImageXPng[] = {'i','m','a','g','e','/','x','-','p','n','g',0}; -static const WCHAR mimeImageTiff[] = {'i','m','a','g','e','/','t','i','f','f',0}; -static const WCHAR mimeVideoAvi[] = {'v','i','d','e','o','/','a','v','i',0}; -static const WCHAR mimeVideoMpeg[] = {'v','i','d','e','o','/','m','p','e','g',0}; -static const WCHAR mimeAppPostscript[] = - {'a','p','p','l','i','c','a','t','i','o','n','/','p','o','s','t','s','c','r','i','p','t',0}; -static const WCHAR mimeAppXCompressed[] = {'a','p','p','l','i','c','a','t','i','o','n','/', - 'x','-','c','o','m','p','r','e','s','s','e','d',0}; -static const WCHAR mimeAppXZip[] = {'a','p','p','l','i','c','a','t','i','o','n','/', - 'x','-','z','i','p','-','c','o','m','p','r','e','s','s','e','d',0}; -static const WCHAR mimeAppXGzip[] = {'a','p','p','l','i','c','a','t','i','o','n','/', - 'x','-','g','z','i','p','-','c','o','m','p','r','e','s','s','e','d',0}; -static const WCHAR mimeAppJava[] = {'a','p','p','l','i','c','a','t','i','o','n','/','j','a','v','a',0}; -static const WCHAR mimeAppPdf[] = {'a','p','p','l','i','c','a','t','i','o','n','/','p','d','f',0}; -static const WCHAR mimeAppXMSDownload[] = - {'a','p','p','l','i','c','a','t','i','o','n','/','x','-','m','s','d','o','w','n','l','o','a','d',0}; -static const WCHAR mimeAudioWav[] = {'a','u','d','i','o','/','w','a','v',0}; -static const WCHAR mimeAudioBasic[] = {'a','u','d','i','o','/','b','a','s','i','c',0}; - static const struct { - LPCWSTR url; - LPCWSTR mime; + const WCHAR *url; + const char *mime; HRESULT hres; } mime_tests[] = { - {url1, mimeTextHtml, S_OK}, - {url2, mimeTextHtml, S_OK}, - {url3, mimeTextHtml, S_OK}, + {url1, "text/html", S_OK}, + {url2, "text/html", S_OK}, + {url3, "text/html", S_OK}, {url4, NULL, E_FAIL}, {url5, NULL, __HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND)}, {url6, NULL, E_FAIL}, @@ -584,119 +584,140 @@ static const struct { BYTE *data; DWORD size; - LPCWSTR mime, mime_pjpeg, broken_mime; + const char *mime; + const char *mime_pjpeg; + const char *broken_mime; + const char *url; + const char *proposed_mime; } mime_tests2[] = { - {data1, sizeof(data1), mimeTextPlain, mimeTextPlain}, - {data2, sizeof(data2), mimeAppOctetStream, mimeImagePjpeg}, - {data3, sizeof(data3), mimeAppOctetStream, mimeImagePjpeg}, - {data4, sizeof(data4), mimeAppOctetStream, mimeImagePjpeg}, - {data5, sizeof(data5), mimeTextPlain, mimeTextPlain}, - {data6, sizeof(data6), mimeTextPlain, mimeTextPlain}, - {data7, sizeof(data7), mimeTextHtml, mimeTextPlain}, - {data8, sizeof(data8), mimeTextHtml, mimeTextPlain}, - {data9, sizeof(data9), mimeTextHtml, mimeImagePjpeg}, - {data10, sizeof(data10), mimeTextHtml, mimeTextPlain}, - {data11, sizeof(data11), mimeTextHtml, mimeTextPlain}, - {data12, sizeof(data12), mimeTextHtml, mimeTextPlain}, - {data13, sizeof(data13), mimeTextPlain, mimeTextPlain}, - {data14, sizeof(data14), mimeTextPlain, mimeTextPlain}, - {data15, sizeof(data15), mimeTextPlain, mimeTextPlain}, - {data16, sizeof(data16), mimeImagePjpeg, mimeImagePjpeg}, - {data17, sizeof(data17), mimeAppOctetStream, mimeImagePjpeg}, - {data18, sizeof(data18), mimeTextHtml, mimeImagePjpeg}, - {data19, sizeof(data19), mimeImageGif, mimeImageGif}, - {data20, sizeof(data20), mimeImageGif, mimeImageGif}, - {data21, sizeof(data21), mimeTextPlain, mimeTextPlain}, - {data22, sizeof(data22), mimeImageGif, mimeImageGif}, - {data23, sizeof(data23), mimeTextPlain, mimeTextPlain}, - {data24, sizeof(data24), mimeImageGif, mimeImageGif}, - {data25, sizeof(data25), mimeImageGif, mimeImageGif}, - {data26, sizeof(data26), mimeTextHtml, mimeImageGif}, - {data27, sizeof(data27), mimeTextPlain, mimeTextPlain}, - {data28, sizeof(data28), mimeImageBmp, mimeImageBmp}, - {data29, sizeof(data29), mimeImageBmp, mimeImageBmp}, - {data30, sizeof(data30), mimeAppOctetStream, mimeImagePjpeg}, - {data31, sizeof(data31), mimeTextHtml, mimeImageBmp}, - {data32, sizeof(data32), mimeAppOctetStream, mimeImagePjpeg}, - {data33, sizeof(data33), mimeAppOctetStream, mimeImagePjpeg}, - {data34, sizeof(data34), mimeImageXPng, mimeImageXPng}, - {data35, sizeof(data35), mimeImageXPng, mimeImageXPng}, - {data36, sizeof(data36), mimeAppOctetStream, mimeImagePjpeg}, - {data37, sizeof(data37), mimeTextHtml, mimeImageXPng}, - {data38, sizeof(data38), mimeAppOctetStream, mimeImagePjpeg}, - {data39, sizeof(data39), mimeImageTiff, mimeImageTiff}, - {data40, sizeof(data40), mimeTextHtml, mimeImageTiff}, - {data41, sizeof(data41), mimeTextPlain, mimeTextPlain, mimeImageTiff}, - {data42, sizeof(data42), mimeTextPlain, mimeTextPlain}, - {data43, sizeof(data43), mimeAppOctetStream, mimeImagePjpeg}, - {data44, sizeof(data44), mimeVideoAvi, mimeVideoAvi}, - {data45, sizeof(data45), mimeTextPlain, mimeTextPlain}, - {data46, sizeof(data46), mimeTextPlain, mimeTextPlain}, - {data47, sizeof(data47), mimeTextPlain, mimeTextPlain}, - {data48, sizeof(data48), mimeTextHtml, mimeVideoAvi}, - {data49, sizeof(data49), mimeVideoAvi, mimeVideoAvi}, - {data50, sizeof(data50), mimeVideoMpeg, mimeVideoMpeg}, - {data51, sizeof(data51), mimeVideoMpeg, mimeVideoMpeg}, - {data52, sizeof(data52), mimeAppOctetStream, mimeImagePjpeg}, - {data53, sizeof(data53), mimeAppOctetStream, mimeImagePjpeg}, - {data54, sizeof(data54), mimeTextHtml, mimeVideoMpeg}, - {data55, sizeof(data55), mimeAppXGzip, mimeAppXGzip}, - {data56, sizeof(data56), mimeTextPlain, mimeTextPlain}, - {data57, sizeof(data57), mimeTextHtml, mimeAppXGzip}, - {data58, sizeof(data58), mimeAppOctetStream, mimeImagePjpeg}, - {data59, sizeof(data59), mimeAppXZip, mimeAppXZip}, - {data60, sizeof(data60), mimeTextPlain, mimeTextPlain}, - {data61, sizeof(data61), mimeTextHtml, mimeAppXZip}, - {data62, sizeof(data62), mimeAppJava, mimeAppJava}, - {data63, sizeof(data63), mimeTextPlain, mimeTextPlain}, - {data64, sizeof(data64), mimeTextHtml, mimeAppJava}, - {data65, sizeof(data65), mimeAppPdf, mimeAppPdf}, - {data66, sizeof(data66), mimeTextPlain, mimeTextPlain}, - {data67, sizeof(data67), mimeTextHtml, mimeAppPdf}, - {data68, sizeof(data68), mimeAppXMSDownload, mimeAppXMSDownload}, - {data69, sizeof(data69), mimeTextPlain, mimeTextPlain}, - {data70, sizeof(data70), mimeTextHtml, mimeAppXMSDownload}, - {data71, sizeof(data71), mimeTextRichtext, mimeTextRichtext}, - {data72, sizeof(data72), mimeTextPlain, mimeTextPlain}, - {data73, sizeof(data73), mimeTextPlain, mimeTextPlain}, - {data74, sizeof(data74), mimeTextHtml, mimeTextRichtext}, - {data75, sizeof(data75), mimeAudioWav, mimeAudioWav}, - {data76, sizeof(data76), mimeTextPlain, mimeTextPlain}, - {data77, sizeof(data77), mimeTextPlain, mimeTextPlain}, - {data78, sizeof(data78), mimeTextHtml, mimeTextPlain}, - {data79, sizeof(data79), mimeAppPostscript, mimeAppPostscript}, - {data80, sizeof(data80), mimeTextPlain, mimeTextPlain}, - {data81, sizeof(data81), mimeTextHtml, mimeAppPostscript}, - {data82, sizeof(data82), mimeAudioBasic, mimeAudioBasic}, - {data83, sizeof(data83), mimeTextPlain, mimeTextPlain}, - {data84, sizeof(data84), mimeTextHtml, mimeAudioBasic}, - {data85, sizeof(data85), mimeTextPlain, mimeTextPlain}, - {data86, sizeof(data86), mimeImageTiff, mimeImageTiff, mimeTextPlain}, - {data87, sizeof(data87), mimeTextPlain, mimeTextPlain}, - {data88, sizeof(data88), mimeTextHtml, mimeTextPlain}, - {data89, sizeof(data89), mimeTextHtml, mimeTextPlain}, - {data90, sizeof(data90), mimeTextHtml, mimeTextPlain}, - {data91, sizeof(data91), mimeTextXml, mimeTextPlain}, - {data92, sizeof(data92), mimeTextXml, mimeTextPlain}, - {data93, sizeof(data93), mimeTextXml, mimeTextPlain}, - {data94, sizeof(data94), mimeTextHtml, mimeTextPlain}, - {data95, sizeof(data95), mimeTextXml, mimeTextRichtext}, - {data96, sizeof(data96), mimeTextPlain, mimeTextPlain} + {data1, sizeof(data1), "text/plain"}, + {data2, sizeof(data2), "application/octet-stream", "image/pjpeg"}, + {data3, sizeof(data3), "application/octet-stream", "image/pjpeg"}, + {data4, sizeof(data4), "application/octet-stream", "image/pjpeg"}, + {data5, sizeof(data5), "text/plain"}, + {data6, sizeof(data6), "text/plain"}, + {data7, sizeof(data7), "text/html", "text/plain"}, + {data8, sizeof(data8), "text/html", "text/plain"}, + {data9, sizeof(data9), "text/html", "image/pjpeg"}, + {data10, sizeof(data10), "text/html", "text/plain"}, + {data11, sizeof(data11), "text/html", "text/plain"}, + {data12, sizeof(data12), "text/html", "text/plain"}, + {data13, sizeof(data13), "text/plain"}, + {data14, sizeof(data14), "text/plain"}, + {data15, sizeof(data15), "text/plain"}, + {data16, sizeof(data16), "image/pjpeg"}, + {data17, sizeof(data17), "application/octet-stream", "image/pjpeg"}, + {data18, sizeof(data18), "text/html", "image/pjpeg"}, + {data19, sizeof(data19), "image/gif"}, + {data20, sizeof(data20), "image/gif"}, + {data21, sizeof(data21), "text/plain"}, + {data22, sizeof(data22), "image/gif"}, + {data23, sizeof(data23), "text/plain"}, + {data24, sizeof(data24), "image/gif"}, + {data25, sizeof(data25), "image/gif"}, + {data26, sizeof(data26), "text/html", "image/gif"}, + {data27, sizeof(data27), "text/plain"}, + {data28, sizeof(data28), "image/bmp"}, + {data29, sizeof(data29), "image/bmp"}, + {data30, sizeof(data30), "application/octet-stream", "image/pjpeg"}, + {data31, sizeof(data31), "text/html", "image/bmp"}, + {data32, sizeof(data32), "application/octet-stream", "image/pjpeg"}, + {data33, sizeof(data33), "application/octet-stream", "image/pjpeg"}, + {data34, sizeof(data34), "image/x-png"}, + {data35, sizeof(data35), "image/x-png"}, + {data36, sizeof(data36), "application/octet-stream", "image/pjpeg"}, + {data37, sizeof(data37), "text/html", "image/x-png"}, + {data38, sizeof(data38), "application/octet-stream", "image/pjpeg"}, + {data39, sizeof(data39), "image/tiff"}, + {data40, sizeof(data40), "text/html", "image/tiff"}, + {data41, sizeof(data41), "text/plain", NULL, "image/tiff"}, + {data42, sizeof(data42), "text/plain"}, + {data43, sizeof(data43), "application/octet-stream", "image/pjpeg"}, + {data44, sizeof(data44), "video/avi"}, + {data45, sizeof(data45), "text/plain"}, + {data46, sizeof(data46), "text/plain"}, + {data47, sizeof(data47), "text/plain"}, + {data48, sizeof(data48), "text/html", "video/avi"}, + {data49, sizeof(data49), "video/avi"}, + {data50, sizeof(data50), "video/mpeg"}, + {data51, sizeof(data51), "video/mpeg"}, + {data52, sizeof(data52), "application/octet-stream", "image/pjpeg"}, + {data53, sizeof(data53), "application/octet-stream", "image/pjpeg"}, + {data54, sizeof(data54), "text/html", "video/mpeg"}, + {data55, sizeof(data55), "application/x-gzip-compressed"}, + {data56, sizeof(data56), "text/plain"}, + {data57, sizeof(data57), "text/html", "application/x-gzip-compressed"}, + {data58, sizeof(data58), "application/octet-stream", "image/pjpeg"}, + {data59, sizeof(data59), "application/x-zip-compressed"}, + {data60, sizeof(data60), "text/plain"}, + {data61, sizeof(data61), "text/html", "application/x-zip-compressed"}, + {data62, sizeof(data62), "application/java"}, + {data63, sizeof(data63), "text/plain"}, + {data64, sizeof(data64), "text/html", "application/java"}, + {data65, sizeof(data65), "application/pdf"}, + {data66, sizeof(data66), "text/plain"}, + {data67, sizeof(data67), "text/html", "application/pdf"}, + {data68, sizeof(data68), "application/x-msdownload"}, + {data69, sizeof(data69), "text/plain"}, + {data70, sizeof(data70), "text/html", "application/x-msdownload"}, + {data71, sizeof(data71), "text/richtext"}, + {data72, sizeof(data72), "text/plain"}, + {data73, sizeof(data73), "text/plain"}, + {data74, sizeof(data74), "text/html", "text/richtext"}, + {data75, sizeof(data75), "audio/wav"}, + {data76, sizeof(data76), "text/plain"}, + {data77, sizeof(data77), "text/plain"}, + {data78, sizeof(data78), "text/html", "text/plain"}, + {data79, sizeof(data79), "application/postscript"}, + {data80, sizeof(data80), "text/plain"}, + {data81, sizeof(data81), "text/html", "application/postscript"}, + {data82, sizeof(data82), "audio/basic"}, + {data83, sizeof(data83), "text/plain"}, + {data84, sizeof(data84), "text/html", "audio/basic"}, + {data85, sizeof(data85), "text/plain"}, + {data86, sizeof(data86), "image/tiff", NULL, "text/plain"}, + {data87, sizeof(data87), "text/plain"}, + {data88, sizeof(data88), "text/html", "text/plain"}, + {data89, sizeof(data89), "text/html", "text/plain"}, + {data90, sizeof(data90), "text/html", "text/plain"}, + {data91, sizeof(data91), "text/xml", "text/plain"}, + {data92, sizeof(data92), "text/xml", "text/plain"}, + {data93, sizeof(data93), "text/xml", "text/plain"}, + {data94, sizeof(data94), "text/html", "text/plain"}, + {data95, sizeof(data95), "text/xml", "text/richtext"}, + {data96, sizeof(data96), "text/plain"}, + {data1, sizeof(data1), "text/plain", NULL, NULL, "res://mshtml.dll/blank.htm"}, + {NULL, 0, "text/html", NULL, NULL, "res://mshtml.dll/blank.htm"}, + {data1, sizeof(data1), "text/plain", NULL, NULL, "res://mshtml.dll/blank.htm", "application/octet-stream"}, + {data1, sizeof(data1), "text/plain", NULL, NULL, "file:some%20file%2ejpg", "application/octet-stream"}, + {NULL, sizeof(data1), "text/html", NULL, NULL, "res://mshtml.dll/blank.htm"}, + {data1, sizeof(data1), "text/css", NULL, NULL, "
http://www.winehq.org/test.css
"}, + {data2, sizeof(data2), "text/css", NULL, NULL, "
http://www.winehq.org/test.css
"}, + {data10, sizeof(data10), "text/html", NULL, NULL, "
http://www.winehq.org/test.css
"}, + {data1, sizeof(data1), "text/css", NULL, NULL, "
http://www.winehq.org/test.css
", "text/plain"}, + {data1, sizeof(data1), "text/css", NULL, NULL, "
http://www.winehq.org/test.css
", "application/octet-stream"}, + {data1, sizeof(data1), "text/test", NULL, NULL, "
http://www.winehq.org/test.css
", "text/test"} }; static void test_FindMimeFromData(void) { + WCHAR *mime, *proposed_mime, *url; HRESULT hres; - LPWSTR mime; BYTE b; int i; + + static const WCHAR app_octet_streamW[] = + {'a','p','p','l','i','c','a','t','i','o','n','/','o','c','t','e','t','-','s','t','r','e','a','m',0}; + static const WCHAR image_pjpegW[] = {'i','m','a','g','e','/','p','j','p','e','g',0}; + static const WCHAR text_htmlW[] = {'t','e','x','t','/','h','t','m','l',0}; + static const WCHAR text_plainW[] = {'t','e','x','t','/','p','l','a','i','n',0}; for(i=0; i<sizeof(mime_tests)/sizeof(mime_tests[0]); i++) { mime = (LPWSTR)0xf0f0f0f0; hres = pFindMimeFromData(NULL, mime_tests[i].url, NULL, 0, NULL, 0, &mime, 0); if(mime_tests[i].mime) { ok(hres == S_OK, "[%d] FindMimeFromData failed: %08x\n", i, hres); - ok(!lstrcmpW(mime, mime_tests[i].mime), "[%d] wrong mime: %s\n", i, wine_dbgstr_w(mime)); + ok(!strcmp_wa(mime, mime_tests[i].mime), "[%d] wrong mime: %s\n", i, wine_dbgstr_w(mime)); CoTaskMemFree(mime); }else { ok(hres == E_FAIL || hres == mime_tests[i].hres, @@ -706,107 +727,72 @@ } mime = (LPWSTR)0xf0f0f0f0; - hres = pFindMimeFromData(NULL, mime_tests[i].url, NULL, 0, mimeTextPlain, 0, &mime, 0); + hres = pFindMimeFromData(NULL, mime_tests[i].url, NULL, 0, text_plainW, 0, &mime, 0); ok(hres == S_OK, "[%d] FindMimeFromData failed: %08x\n", i, hres); - ok(!lstrcmpW(mime, mimeTextPlain), "[%d] wrong mime: %s\n", i, wine_dbgstr_w(mime)); + ok(!strcmp_wa(mime, "text/plain"), "[%d] wrong mime: %s\n", i, wine_dbgstr_w(mime)); CoTaskMemFree(mime); mime = (LPWSTR)0xf0f0f0f0; - hres = pFindMimeFromData(NULL, mime_tests[i].url, NULL, 0, mimeAppOctetStream, 0, &mime, 0); + hres = pFindMimeFromData(NULL, mime_tests[i].url, NULL, 0, app_octet_streamW, 0, &mime, 0); ok(hres == S_OK, "[%d] FindMimeFromData failed: %08x\n", i, hres); - ok(!lstrcmpW(mime, mimeAppOctetStream), "[%d] wrong mime: %s\n", i, wine_dbgstr_w(mime)); + ok(!strcmp_wa(mime, "application/octet-stream"), "[%d] wrong mime: %s\n", i, wine_dbgstr_w(mime)); CoTaskMemFree(mime); } for(i=0; i < sizeof(mime_tests2)/sizeof(mime_tests2[0]); i++) { + url = a2w(mime_tests2[i].url); + proposed_mime = a2w(mime_tests2[i].proposed_mime); + hres = pFindMimeFromData(NULL, url, mime_tests2[i].data, mime_tests2[i].size, + proposed_mime, 0, &mime, 0); + ok(hres == S_OK, "[%d] FindMimeFromData failed: %08x\n", i, hres); + b = !strcmp_wa(mime, mime_tests2[i].mime); + ok(b || broken(mime_tests2[i].broken_mime && !strcmp_wa(mime, mime_tests2[i].broken_mime)), + "[%d] wrong mime: %s\n", i, wine_dbgstr_w(mime)); + heap_free(proposed_mime); + heap_free(url); + CoTaskMemFree(mime); + if(!b || url || proposed_mime) + continue; + hres = pFindMimeFromData(NULL, NULL, mime_tests2[i].data, mime_tests2[i].size, - NULL, 0, &mime, 0); + app_octet_streamW, 0, &mime, 0); ok(hres == S_OK, "[%d] FindMimeFromData failed: %08x\n", i, hres); - b = !lstrcmpW(mime, mime_tests2[i].mime); - ok(b || broken(mime_tests2[i].broken_mime && !lstrcmpW(mime, mime_tests2[i].broken_mime)), - "[%d] wrong mime: %s\n", i, wine_dbgstr_w(mime)); - CoTaskMemFree(mime); - if(!b) - continue; - - hres = pFindMimeFromData(NULL, NULL, mime_tests2[i].data, mime_tests2[i].size, - mimeAppOctetStream, 0, &mime, 0); - ok(hres == S_OK, "[%d] FindMimeFromData failed: %08x\n", i, hres); - ok(!lstrcmpW(mime, mime_tests2[i].mime) || broken(mime_tests2[i].broken_mime - && !lstrcmpW(mime, mime_tests2[i].broken_mime)), + ok(!strcmp_wa(mime, mime_tests2[i].mime) || broken(mime_tests2[i].broken_mime + && !strcmp_wa(mime, mime_tests2[i].broken_mime)), "[%d] wrong mime: %s\n", i, wine_dbgstr_w(mime)); CoTaskMemFree(mime); hres = pFindMimeFromData(NULL, NULL, mime_tests2[i].data, mime_tests2[i].size, - mimeTextPlain, 0, &mime, 0); + text_plainW, 0, &mime, 0); ok(hres == S_OK, "[%d] FindMimeFromData failed: %08x\n", i, hres); - ok(!lstrcmpW(mime, mime_tests2[i].mime) || broken(mime_tests2[i].broken_mime - && !lstrcmpW(mime, mime_tests2[i].broken_mime)), + ok(!strcmp_wa(mime, mime_tests2[i].mime) || broken(mime_tests2[i].broken_mime + && !strcmp_wa(mime, mime_tests2[i].broken_mime)), "[%d] wrong mime: %s\n", i, wine_dbgstr_w(mime)); CoTaskMemFree(mime); hres = pFindMimeFromData(NULL, NULL, mime_tests2[i].data, mime_tests2[i].size, - mimeTextHtml, 0, &mime, 0); + text_htmlW, 0, &mime, 0); ok(hres == S_OK, "[%d] FindMimeFromData failed: %08x\n", i, hres); - if(!lstrcmpW(mimeAppOctetStream, mime_tests2[i].mime) - || !lstrcmpW(mimeTextPlain, mime_tests2[i].mime) || i==92) - ok(!lstrcmpW(mime, mimeTextHtml), "[%d] wrong mime: %s\n", i, wine_dbgstr_w(mime)); + if(!strcmp("application/octet-stream", mime_tests2[i].mime) + || !strcmp("text/plain", mime_tests2[i].mime) || i==92) + ok(!strcmp_wa(mime, "text/html"), "[%d] wrong mime: %s\n", i, wine_dbgstr_w(mime)); else - ok(!lstrcmpW(mime, mime_tests2[i].mime), "[%d] wrong mime: %s\n", i, wine_dbgstr_w(mime)); + ok(!strcmp_wa(mime, mime_tests2[i].mime), "[%d] wrong mime: %s\n", i, wine_dbgstr_w(mime)); CoTaskMemFree(mime); hres = pFindMimeFromData(NULL, NULL, mime_tests2[i].data, mime_tests2[i].size, - mimeImagePjpeg, 0, &mime, 0); + image_pjpegW, 0, &mime, 0); ok(hres == S_OK, "[%d] FindMimeFromData failed: %08x\n", i, hres); - ok(!lstrcmpW(mime, mime_tests2[i].mime_pjpeg) || broken(!lstrcmpW(mime, mime_tests2[i].mime)), - "[%d] wrong mime, got %s\n", i, wine_dbgstr_w(mime)); + ok(!strcmp_wa(mime, mime_tests2[i].mime_pjpeg ? mime_tests2[i].mime_pjpeg : mime_tests2[i].mime) + || broken(!strcmp_wa(mime, mime_tests2[i].mime)), + "[%d] wrong mime, got %s\n", i, wine_dbgstr_w(mime)); CoTaskMemFree(mime); } - - hres = pFindMimeFromData(NULL, url1, data1, sizeof(data1), NULL, 0, &mime, 0); - ok(hres == S_OK, "FindMimeFromData failed: %08x\n", hres); - ok(!lstrcmpW(mime, mimeTextPlain), "wrong mime: %s\n", wine_dbgstr_w(mime)); - CoTaskMemFree(mime); - - hres = pFindMimeFromData(NULL, url1, data1, sizeof(data1), mimeAppOctetStream, 0, &mime, 0); - ok(hres == S_OK, "FindMimeFromData failed: %08x\n", hres); - ok(!lstrcmpW(mime, mimeTextPlain), "wrong mime: %s\n", wine_dbgstr_w(mime)); - CoTaskMemFree(mime); - - hres = pFindMimeFromData(NULL, url4, data1, sizeof(data1), mimeAppOctetStream, 0, &mime, 0); - ok(hres == S_OK, "FindMimeFromData failed: %08x\n", hres); - ok(!lstrcmpW(mime, mimeTextPlain), "wrong mime: %s\n", wine_dbgstr_w(mime)); - CoTaskMemFree(mime); - - hres = pFindMimeFromData(NULL, url1, NULL, 0, NULL, 0, &mime, 0); - ok(hres == S_OK, "FindMimeFromData failed: %08x, expected S_OK\n", hres); - ok(!lstrcmpW(mime, mimeTextHtml), "wrong mime: %s\n", wine_dbgstr_w(mime)); - CoTaskMemFree(mime); - - hres = pFindMimeFromData(NULL, url1, NULL, sizeof(data1), NULL, 0, &mime, 0); - ok(hres == S_OK, "FindMimeFromData failed: %08x, expected S_OK\n", hres); - ok(!lstrcmpW(mime, mimeTextHtml), "wrong mime: %s\n", wine_dbgstr_w(mime)); - CoTaskMemFree(mime); - - hres = pFindMimeFromData(NULL, url1, 0, 0, NULL, 0, &mime, 0); - ok(hres == S_OK, "FindMimeFromData failed: %08x, expected S_OK\n", hres); - ok(!lstrcmpW(mime, mimeTextHtml), "wrong mime: %s\n", wine_dbgstr_w(mime)); - CoTaskMemFree(mime); - - hres = pFindMimeFromData(NULL, url1, 0, sizeof(data1), NULL, 0, &mime, 0); - ok(hres == S_OK, "FindMimeFromData failed: %08x, expected S_OK\n", hres); - ok(!lstrcmpW(mime, mimeTextHtml), "wrong mime: %s\n", wine_dbgstr_w(mime)); - CoTaskMemFree(mime); - - hres = pFindMimeFromData(NULL, url1, data1, sizeof(data1), NULL, 0, &mime, 0); - ok(hres == S_OK, "FindMimeFromData failed: %08x, expected S_OK\n", hres); - ok(!lstrcmpW(mime, mimeTextPlain), "wrong mime: %s\n", wine_dbgstr_w(mime)); - CoTaskMemFree(mime); hres = pFindMimeFromData(NULL, NULL, NULL, 0, NULL, 0, &mime, 0); ok(hres == E_INVALIDARG, "FindMimeFromData failed: %08x, expected E_INVALIDARG\n", hres); - hres = pFindMimeFromData(NULL, NULL, NULL, 0, mimeTextPlain, 0, &mime, 0); + hres = pFindMimeFromData(NULL, NULL, NULL, 0, text_plainW, 0, &mime, 0); ok(hres == E_INVALIDARG, "FindMimeFromData failed: %08x, expected E_INVALIDARG\n", hres); hres = pFindMimeFromData(NULL, NULL, data1, 0, NULL, 0, &mime, 0); @@ -815,12 +801,12 @@ hres = pFindMimeFromData(NULL, url1, data1, 0, NULL, 0, &mime, 0); ok(hres == E_FAIL, "FindMimeFromData failed: %08x, expected E_FAIL\n", hres); - hres = pFindMimeFromData(NULL, NULL, data1, 0, mimeTextPlain, 0, &mime, 0); + hres = pFindMimeFromData(NULL, NULL, data1, 0, text_plainW, 0, &mime, 0); ok(hres == S_OK, "FindMimeFromData failed: %08x\n", hres); - ok(!lstrcmpW(mime, mimeTextPlain), "wrong mime: %s\n", wine_dbgstr_w(mime)); + ok(!strcmp_wa(mime, "text/plain"), "wrong mime: %s\n", wine_dbgstr_w(mime)); CoTaskMemFree(mime); - hres = pFindMimeFromData(NULL, NULL, data1, 0, mimeTextPlain, 0, NULL, 0); + hres = pFindMimeFromData(NULL, NULL, data1, 0, text_plainW, 0, NULL, 0); ok(hres == E_INVALIDARG, "FindMimeFromData failed: %08x, expected E_INVALIDARG\n", hres); } Modified: trunk/rostests/winetests/urlmon/protocol.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/urlmon/protocol…
============================================================================== --- trunk/rostests/winetests/urlmon/protocol.c [iso-8859-1] (original) +++ trunk/rostests/winetests/urlmon/protocol.c [iso-8859-1] Sat Sep 28 15:09:44 2013 @@ -3729,7 +3729,7 @@ if(!winetest_interactive) { - skip("protocol test skipped, bug 6381\n"); + skip("protocol test skipped, ROSTESTS-38\n"); return; } Modified: trunk/rostests/winetests/urlmon/sec_mgr.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/urlmon/sec_mgr.…
============================================================================== --- trunk/rostests/winetests/urlmon/sec_mgr.c [iso-8859-1] (original) +++ trunk/rostests/winetests/urlmon/sec_mgr.c [iso-8859-1] Sat Sep 28 15:09:44 2013 @@ -27,6 +27,7 @@ #define NONAMELESSUNION /* needed for IInternetZoneManagerEx2 */ +#undef _WIN32_IE #define _WIN32_IE 0x0700 #include <wine/test.h> Modified: trunk/rostests/winetests/urlmon/uri.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/urlmon/uri.c?re…
============================================================================== --- trunk/rostests/winetests/urlmon/uri.c [iso-8859-1] (original) +++ trunk/rostests/winetests/urlmon/uri.c [iso-8859-1] Sat Sep 28 15:09:44 2013 @@ -367,6 +367,31 @@ {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, + { "file:///z:/test dir/README.txt", 0, S_OK, FALSE, + { + {"file:///z:/test%20dir/README.txt",S_OK}, + {"",S_FALSE}, + {"file:///z:/test%20dir/README.txt",S_OK}, + {"",S_FALSE}, + {".txt",S_OK}, + {"",S_FALSE}, + {"",S_FALSE}, + {"",S_FALSE}, + {"/z:/test%20dir/README.txt",S_OK}, + {"/z:/test%20dir/README.txt",S_OK}, + {"",S_FALSE}, + {"file:///z:/test dir/README.txt",S_OK}, + {"file",S_OK}, + {"",S_FALSE}, + {"",S_FALSE} + }, + { + {Uri_HOST_UNKNOWN,S_OK,FALSE}, + {0,S_FALSE,FALSE}, + {URL_SCHEME_FILE,S_OK,FALSE}, + {URLZONE_INVALID,E_NOTIMPL,FALSE} + } + }, { "urn:nothing:should:happen here", 0, S_OK, FALSE, { {"urn:nothing:should:happen here",S_OK,FALSE}, @@ -4503,7 +4528,57 @@ {URL_SCHEME_UNKNOWN,S_OK}, {URLZONE_INVALID,E_NOTIMPL} } - } + }, + { "mailto://", Uri_CREATE_NO_CANONICALIZE, S_OK, FALSE, + { + {"mailto:",S_OK}, + {"",S_FALSE}, + {"mailto:",S_OK}, + {"",S_FALSE}, + {"",S_FALSE}, + {"",S_FALSE}, + {"",S_FALSE}, + {"",S_FALSE}, + {"",S_FALSE}, + {"",S_FALSE}, + {"",S_FALSE}, + {"mailto://",S_OK,FALSE,"mailto:"}, + {"mailto",S_OK}, + {"",S_FALSE}, + {"",S_FALSE} + }, + { + {Uri_HOST_UNKNOWN,S_OK}, + {0,S_FALSE}, + {URL_SCHEME_MAILTO,S_OK}, + {URLZONE_INVALID,E_NOTIMPL} + } + }, + { "mailto://a@b.com", Uri_CREATE_NO_CANONICALIZE, S_OK, FALSE, + { + {"mailto:a@b.com",S_OK}, + {"",S_FALSE}, + {"mailto:a@b.com",S_OK}, + {"",S_FALSE}, + {".com",S_OK}, + {"",S_FALSE}, + {"",S_FALSE}, + {"",S_FALSE}, + {"a(a)b.com",S_OK}, + {"a(a)b.com",S_OK}, + {"",S_FALSE}, + {"mailto://a@b.com",S_OK,FALSE,"mailto:a@b.com"}, + {"mailto",S_OK}, + {"",S_FALSE}, + {"",S_FALSE} + }, + { + {Uri_HOST_UNKNOWN,S_OK}, + {0,S_FALSE}, + {URL_SCHEME_MAILTO,S_OK}, + {URLZONE_INVALID,E_NOTIMPL} + } + } }; typedef struct _invalid_uri { @@ -6933,6 +7008,114 @@ {URL_SCHEME_HTTP,S_OK}, {URLZONE_INVALID,E_NOTIMPL} } + }, + { "
http://google.com/test
",0, + "c:\\test\\", Uri_CREATE_ALLOW_IMPLICIT_FILE_SCHEME, + 0,S_OK,FALSE, + { + {"file:///c:/test/",S_OK}, + {"",S_FALSE}, + {"file:///c:/test/",S_OK}, + {"",S_FALSE}, + {"",S_FALSE}, + {"",S_FALSE}, + {"",S_FALSE}, + {"",S_FALSE}, + {"/c:/test/",S_OK}, + {"/c:/test/",S_OK}, + {"",S_FALSE}, + {"c:\\test\\",S_OK,FALSE,"file:///c:/test/"}, + {"file",S_OK}, + {"",S_FALSE}, + {"",S_FALSE} + }, + { + {Uri_HOST_UNKNOWN,S_OK}, + {0,S_FALSE}, + {URL_SCHEME_FILE,S_OK}, + {URLZONE_INVALID,E_NOTIMPL} + } + }, + { "
http://google.com/test
",0, + "c:\\test\\", Uri_CREATE_ALLOW_IMPLICIT_FILE_SCHEME, + 0,S_OK,FALSE, + { + {"file:///c:/test/",S_OK}, + {"",S_FALSE}, + {"file:///c:/test/",S_OK}, + {"",S_FALSE}, + {"",S_FALSE}, + {"",S_FALSE}, + {"",S_FALSE}, + {"",S_FALSE}, + {"/c:/test/",S_OK}, + {"/c:/test/",S_OK}, + {"",S_FALSE}, + {"c:\\test\\",S_OK,FALSE,"file:///c:/test/"}, + {"file",S_OK}, + {"",S_FALSE}, + {"",S_FALSE} + }, + { + {Uri_HOST_UNKNOWN,S_OK}, + {0,S_FALSE}, + {URL_SCHEME_FILE,S_OK}, + {URLZONE_INVALID,E_NOTIMPL} + } + }, + { "
http://winehq.org
",0, + "mailto://",Uri_CREATE_NO_CANONICALIZE, + 0,S_OK,FALSE, + { + {"mailto:",S_OK}, + {"",S_FALSE}, + {"mailto:",S_OK}, + {"",S_FALSE}, + {"",S_FALSE}, + {"",S_FALSE}, + {"",S_FALSE}, + {"",S_FALSE}, + {"",S_FALSE}, + {"",S_FALSE}, + {"",S_FALSE}, + {"mailto://",S_OK,FALSE,"mailto:"}, + {"mailto",S_OK}, + {"",S_FALSE}, + {"",S_FALSE} + }, + { + {Uri_HOST_UNKNOWN,S_OK}, + {0,S_FALSE}, + {URL_SCHEME_MAILTO,S_OK}, + {URLZONE_INVALID,E_NOTIMPL} + } + }, + { "
http://winehq.org
",0, + "mailto://a@b.com",Uri_CREATE_NO_CANONICALIZE, + 0,S_OK,FALSE, + { + {"mailto:a@b.com",S_OK}, + {"",S_FALSE}, + {"mailto:a@b.com",S_OK}, + {"",S_FALSE}, + {".com",S_OK}, + {"",S_FALSE}, + {"",S_FALSE}, + {"",S_FALSE}, + {"a(a)b.com",S_OK}, + {"a(a)b.com",S_OK}, + {"",S_FALSE}, + {"mailto://a@b.com",S_OK,FALSE,"mailto:a@b.com"}, + {"mailto",S_OK}, + {"",S_FALSE}, + {"",S_FALSE} + }, + { + {Uri_HOST_UNKNOWN,S_OK}, + {0,S_FALSE}, + {URL_SCHEME_MAILTO,S_OK}, + {URLZONE_INVALID,E_NOTIMPL} + } } }; @@ -10244,7 +10427,7 @@ todo_wine { ok(!strcmp_aw(prop.value, received) || broken(prop.broken_value && !strcmp_aw(prop.broken_value, received)), - "Error: Expected %s but got %s instead on uri_combine_tests[%d].str_props[%d].\n", + "Error: Expected \"%s\" but got %s instead on uri_combine_tests[%d].str_props[%d].\n", prop.value, wine_dbgstr_w(received), i, j); } } else { @@ -10253,7 +10436,7 @@ hr, prop.expected, i, j); ok(!strcmp_aw(prop.value, received) || broken(prop.broken_value && !strcmp_aw(prop.broken_value, received)), - "Error: Expected %s but got %s instead on uri_combine_tests[%d].str_props[%d].\n", + "Error: Expected \"%s\" but got %s instead on uri_combine_tests[%d].str_props[%d].\n", prop.value, wine_dbgstr_w(received), i, j); } SysFreeString(received); @@ -10561,7 +10744,7 @@ todo_wine { ok(!strcmp_aw(value, received) || broken(prop.broken_value && !strcmp_aw(prop.broken_value, received)), - "Error: Expected %s but got %s instead on uri_combine_tests[%d].str_props[%d].\n", + "Error: Expected \"%s\" but got %s instead on uri_combine_tests[%d].str_props[%d].\n", value, wine_dbgstr_w(received), i, j); } } else { @@ -10570,7 +10753,7 @@ hr, prop.expected, i, j); ok(!strcmp_aw(value, received) || broken(prop.broken_value && !strcmp_aw(prop.broken_value, received)), - "Error: Expected %s but got %s instead on uri_combine_tests[%d].str_props[%d].\n", + "Error: Expected \"%s\" but got %s instead on uri_combine_tests[%d].str_props[%d].\n", value, wine_dbgstr_w(received), i, j); } SysFreeString(received); Modified: trunk/rostests/winetests/urlmon/url.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/winetests/urlmon/url.c?re…
============================================================================== --- trunk/rostests/winetests/urlmon/url.c [iso-8859-1] (original) +++ trunk/rostests/winetests/urlmon/url.c [iso-8859-1] Sat Sep 28 15:09:44 2013 @@ -153,6 +153,7 @@ DEFINE_EXPECT(SetPriority); DEFINE_EXPECT(GetWindow_IHttpSecurity); DEFINE_EXPECT(GetWindow_IWindowForBindingUI); +DEFINE_EXPECT(GetWindow_ICodeInstall); DEFINE_EXPECT(OnSecurityProblem); static const WCHAR winetest_data_urlW[] = @@ -195,6 +196,7 @@ static BOOL abort_start = FALSE; static BOOL abort_progress = FALSE; static BOOL async_switch = FALSE; +static const char *test_file; static WCHAR file_url[INTERNET_MAX_URL_LENGTH], current_url[INTERNET_MAX_URL_LENGTH]; @@ -1358,6 +1360,8 @@ CHECK_EXPECT(GetWindow_IHttpSecurity); else if(IsEqualGUID(rguidReason, &IID_IWindowForBindingUI)) CHECK_EXPECT2(GetWindow_IWindowForBindingUI); + else if(IsEqualGUID(rguidReason, &IID_ICodeInstall)) + CHECK_EXPECT(GetWindow_ICodeInstall); else ok(0, "Unexpected rguidReason: %s\n", debugstr_guid(rguidReason)); @@ -1892,7 +1896,7 @@ ok(res == hresult, "res = %08x, expected %08x\n", res, binding_hres); ok(!res_str, "incorrect res_str = %s\n", wine_dbgstr_w(res_str)); - if(hresult==S_OK || (abort_start && hresult!=S_FALSE)) { + if(hresult==S_OK || (abort_start && hresult!=S_FALSE) || hresult == REGDB_E_CLASSNOTREG) { ok(IsEqualCLSID(&clsid, &CLSID_NULL), "incorrect protocol CLSID: %s, expected CLSID_NULL\n", debugstr_guid(&clsid)); @@ -3205,7 +3209,7 @@ } } -static void test_BindToObject(int protocol, DWORD flags) +static void test_BindToObject(int protocol, DWORD flags, HRESULT exhres) { IMoniker *mon; HRESULT hres; @@ -3217,6 +3221,7 @@ IBinding *bind; init_bind_test(protocol, BINDTEST_TOOBJECT|flags, TYMED_ISTREAM); + binding_hres = exhres; if(emulate_protocol) CoRegisterClassObject(&CLSID_HTMLDocument, (IUnknown *)&mime_cf, @@ -3287,10 +3292,17 @@ if(test_protocol == HTTP_TEST || test_protocol == HTTPS_TEST) SET_EXPECT(OnProgress_DOWNLOADINGDATA); SET_EXPECT(Obj_OnProgress_ENDDOWNLOADDATA); - SET_EXPECT(Obj_OnProgress_CLASSIDAVAILABLE); + if(SUCCEEDED(hres)) + SET_EXPECT(Obj_OnProgress_CLASSIDAVAILABLE); SET_EXPECT(Obj_OnProgress_BEGINSYNCOPERATION); + if(exhres == REGDB_E_CLASSNOTREG) { + SET_EXPECT(QueryInterface_IWindowForBindingUI); + SET_EXPECT(QueryService_IWindowForBindingUI); + SET_EXPECT(GetWindow_ICodeInstall); + } SET_EXPECT(Obj_OnProgress_ENDSYNCOPERATION); - SET_EXPECT(OnObjectAvailable); + if(SUCCEEDED(hres)) + SET_EXPECT(OnObjectAvailable); SET_EXPECT(Obj_OnStopBinding); } @@ -3303,10 +3315,10 @@ return; } - /* no point testing the calls if binding didn't even work */ - if (FAILED(hres)) return; - - if(bindf & BINDF_ASYNCHRONOUS) { + if(FAILED(exhres)) { + ok(hres == exhres, "BindToObject failed: %08x, expected %08x\n", hres, exhres); + ok(!unk, "unk = %p, expected NULL\n", unk); + }else if(bindf & BINDF_ASYNCHRONOUS) { ok(hres == MK_S_ASYNCHRONOUS, "IMoniker_BindToObject failed: %08x\n", hres); ok(unk == NULL, "istr should be NULL\n"); }else { @@ -3376,10 +3388,17 @@ if(test_protocol == HTTP_TEST || test_protocol == HTTPS_TEST) CLEAR_CALLED(OnProgress_DOWNLOADINGDATA); CLEAR_CALLED(Obj_OnProgress_ENDDOWNLOADDATA); - CHECK_CALLED(Obj_OnProgress_CLASSIDAVAILABLE); + if(SUCCEEDED(hres)) + CHECK_CALLED(Obj_OnProgress_CLASSIDAVAILABLE); CHECK_CALLED(Obj_OnProgress_BEGINSYNCOPERATION); + if(exhres == REGDB_E_CLASSNOTREG) { + todo_wine CHECK_CALLED(QueryInterface_IWindowForBindingUI); + todo_wine CHECK_CALLED(QueryService_IWindowForBindingUI); + todo_wine CHECK_CALLED(GetWindow_ICodeInstall); + } CHECK_CALLED(Obj_OnProgress_ENDSYNCOPERATION); - CHECK_CALLED(OnObjectAvailable); + if(SUCCEEDED(hres)) + CHECK_CALLED(OnObjectAvailable); CHECK_CALLED(Obj_OnStopBinding); } @@ -3614,27 +3633,33 @@ MultiByteToWideChar(CP_ACP, 0, file_urlA, -1, file_url, INTERNET_MAX_URL_LENGTH); } -static void create_file(void) +static void create_file(const char *file_name, const char *content) { HANDLE file; DWORD size; CHAR path[MAX_PATH]; - static const char html_doc[] = "<HTML></HTML>"; - - file = CreateFileA(wszIndexHtmlA, GENERIC_WRITE, 0, NULL, CREATE_ALWAYS, + file = CreateFileA(file_name, GENERIC_WRITE, 0, NULL, CREATE_ALWAYS, FILE_ATTRIBUTE_NORMAL, NULL); ok(file != INVALID_HANDLE_VALUE, "CreateFile failed\n"); if(file == INVALID_HANDLE_VALUE) return; - WriteFile(file, html_doc, sizeof(html_doc)-1, &size, NULL); + if(test_file) + DeleteFileA(test_file); + test_file = file_name; + WriteFile(file, content, strlen(content), &size, NULL); CloseHandle(file); GetCurrentDirectoryA(MAX_PATH, path); lstrcatA(path, "\\"); - lstrcatA(path, wszIndexHtmlA); + lstrcatA(path, file_name); set_file_url(path); +} + +static void create_html_file(void) +{ + create_file(wszIndexHtmlA, "<HTML></HTML>"); } static void create_cache_file(void) @@ -3833,7 +3858,7 @@ complete_event = CreateEvent(NULL, FALSE, FALSE, NULL); complete_event2 = CreateEvent(NULL, FALSE, FALSE, NULL); thread_id = GetCurrentThreadId(); - create_file(); + create_html_file(); create_cache_file(); register_protocols(); @@ -3865,7 +3890,7 @@ test_BindToStorage(HTTP_TEST, BINDTEST_EMULATE, TYMED_FILE); trace("synchronous http test (to object)...\n"); - test_BindToObject(HTTP_TEST, 0); + test_BindToObject(HTTP_TEST, 0, S_OK); trace("emulated synchronous http test (with cache)...\n"); test_BindToStorage(HTTP_TEST, BINDTEST_EMULATE|BINDTEST_USE_CACHE, TYMED_ISTREAM); @@ -3883,7 +3908,12 @@ test_BindToStorage(FILE_TEST, BINDTEST_EMULATE, TYMED_FILE); trace("synchronous file test (to object)...\n"); - test_BindToObject(FILE_TEST, 0); + test_BindToObject(FILE_TEST, 0, S_OK); + + trace("bind to an object of not registered MIME type...\n"); + create_file("test.winetest", "\x01\x02\x03xxxxxxxxxxxxxxxxxxxxxxxxx"); + test_BindToObject(FILE_TEST, 0, REGDB_E_CLASSNOTREG); + create_html_file(); trace("file test (no callback)...\n"); test_BindToStorage(FILE_TEST, BINDTEST_NO_CALLBACK, TYMED_ISTREAM); @@ -3921,13 +3951,13 @@ test_BindToStorage(HTTP_TEST, 0, TYMED_FILE); trace("http test (to object)...\n"); - test_BindToObject(HTTP_TEST, 0); + test_BindToObject(HTTP_TEST, 0, S_OK); trace("http test (short response)...\n"); test_BindToStorage(HTTP_TEST, BINDTEST_HTTPRESPONSE, TYMED_ISTREAM); trace("http test (short response, to object)...\n"); - test_BindToObject(HTTP_TEST, 0); + test_BindToObject(HTTP_TEST, 0, S_OK); trace("http test (abort start binding E_NOTIMPL)...\n"); abort_hres = E_NOTIMPL; @@ -3944,10 +3974,10 @@ test_BindToStorage(HTTP_TEST, BINDTEST_EMULATE, TYMED_ISTREAM); trace("emulated http test (to object)...\n"); - test_BindToObject(HTTP_TEST, BINDTEST_EMULATE); + test_BindToObject(HTTP_TEST, BINDTEST_EMULATE, S_OK); trace("emulated http test (to object, redirect)...\n"); - test_BindToObject(HTTP_TEST, BINDTEST_EMULATE|BINDTEST_REDIRECT); + test_BindToObject(HTTP_TEST, BINDTEST_EMULATE|BINDTEST_REDIRECT, S_OK); trace("emulated http test (to file)...\n"); test_BindToStorage(HTTP_TEST, BINDTEST_EMULATE, TYMED_FILE); @@ -3975,7 +4005,7 @@ test_BindToStorage(ABOUT_TEST, 0, TYMED_FILE); trace("about test (to object)...\n"); - test_BindToObject(ABOUT_TEST, 0); + test_BindToObject(ABOUT_TEST, 0, S_OK); trace("emulated about test...\n"); test_BindToStorage(ABOUT_TEST, BINDTEST_EMULATE, TYMED_ISTREAM); @@ -3984,7 +4014,7 @@ test_BindToStorage(ABOUT_TEST, BINDTEST_EMULATE, TYMED_FILE); trace("emulated about test (to object)...\n"); - test_BindToObject(ABOUT_TEST, BINDTEST_EMULATE); + test_BindToObject(ABOUT_TEST, BINDTEST_EMULATE, S_OK); trace("emulalated test reporting result in read...\n"); test_BindToStorage(WINETEST_SYNC_TEST, BINDTEST_EMULATE, TYMED_ISTREAM); @@ -3996,7 +4026,7 @@ test_BindToStorage(FILE_TEST, 0, TYMED_FILE); trace("file test (to object)...\n"); - test_BindToObject(FILE_TEST, 0); + test_BindToObject(FILE_TEST, 0, S_OK); trace("emulated file test...\n"); test_BindToStorage(FILE_TEST, BINDTEST_EMULATE, TYMED_ISTREAM); @@ -4005,7 +4035,7 @@ test_BindToStorage(FILE_TEST, BINDTEST_EMULATE, TYMED_FILE); trace("emulated file test (to object)...\n"); - test_BindToObject(FILE_TEST, BINDTEST_EMULATE); + test_BindToObject(FILE_TEST, BINDTEST_EMULATE, S_OK); trace("emulated its test...\n"); test_BindToStorage(ITS_TEST, BINDTEST_EMULATE, TYMED_ISTREAM); @@ -4046,7 +4076,7 @@ test_BindToStorage(HTTP_TEST, BINDTEST_EMULATE, TYMED_ISTREAM); } - DeleteFileA(wszIndexHtmlA); + DeleteFileA(test_file); DeleteFileA(test_txtA); CloseHandle(complete_event); CloseHandle(complete_event2);
11 years, 2 months
1
0
0
0
← Newer
1
...
4
5
6
7
8
9
10
...
56
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
Results per page:
10
25
50
100
200