mirror of
git://source.winehq.org/git/wine.git
synced 2024-09-06 04:20:56 +00:00
jscript: Added jsstr_flatten helper and use it to access string buffer in date.c.
This commit is contained in:
parent
16668e82fe
commit
e3d940334f
|
@ -2054,7 +2054,9 @@ static inline HRESULT date_parse(jsstr_t *input_str, double *ret) {
|
|||
DWORD lcid_en;
|
||||
|
||||
input_len = jsstr_length(input_str);
|
||||
input = input_str->str;
|
||||
input = jsstr_flatten(input_str);
|
||||
if(!input)
|
||||
return E_OUTOFMEMORY;
|
||||
|
||||
for(i=0; i<input_len; i++) {
|
||||
if(input[i] == '(') nest_level++;
|
||||
|
|
|
@ -53,6 +53,12 @@ static inline jsstr_t *jsstr_addref(jsstr_t *str)
|
|||
return str;
|
||||
}
|
||||
|
||||
/* This will be failable in the future. */
|
||||
static inline const WCHAR *jsstr_flatten(jsstr_t *str)
|
||||
{
|
||||
return str->str;
|
||||
}
|
||||
|
||||
static inline BOOL jsstr_eq(jsstr_t *str1, jsstr_t *str2)
|
||||
{
|
||||
unsigned len = jsstr_length(str1);
|
||||
|
|
Loading…
Reference in a new issue