winehq.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
2025
February
January
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
January
2003
December
November
October
September
August
July
June
May
April
March
February
January
2002
December
November
October
September
August
July
June
May
April
March
February
January
2001
December
November
October
September
August
July
June
May
April
March
February
List overview
wine-commits
February 2013
----- 2025 -----
February 2025
January 2025
----- 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
January 2004
----- 2003 -----
December 2003
November 2003
October 2003
September 2003
August 2003
July 2003
June 2003
May 2003
April 2003
March 2003
February 2003
January 2003
----- 2002 -----
December 2002
November 2002
October 2002
September 2002
August 2002
July 2002
June 2002
May 2002
April 2002
March 2002
February 2002
January 2002
----- 2001 -----
December 2001
November 2001
October 2001
September 2001
August 2001
July 2001
June 2001
May 2001
April 2001
March 2001
February 2001
wine-commits@winehq.org
2 participants
459 discussions
Start a n
N
ew thread
Tag wine-1.5.24 : Alexandre Julliard : Release 1.5.24
by Alexandre Julliard
15 Feb '13
15 Feb '13
Module: wine Branch: refs/tags/wine-1.5.24 Tag: 9d9fff69a9641e739f497726875704023b93cc7e URL:
http://source.winehq.org/git/wine.git/?a=tag;h=9d9fff69a9641e739f4977268757…
Tagger: Alexandre Julliard <julliard(a)winehq.org> Date: Fri Feb 15 21:21:18 2013 +0100 Release 1.5.24
1
0
0
0
Alexandre Julliard : Release 1.5.24.
by Alexandre Julliard
15 Feb '13
15 Feb '13
Module: wine Branch: master Commit: c41f6add0563252a5809c3c83cbb6a6e6f81c2d9 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=c41f6add0563252a5809c3c83…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Fri Feb 15 21:21:05 2013 +0100 Release 1.5.24. --- ANNOUNCE | 727 +++++++++++++++++++++++++++---------------------------------- VERSION | 2 +- configure | 18 +- 3 files changed, 335 insertions(+), 412 deletions(-) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=c41f6add0563252a5809c…
1
0
0
0
Huw Davies : riched20: Use ME_PointFromChar to calculate the caret position .
by Alexandre Julliard
15 Feb '13
15 Feb '13
Module: wine Branch: master Commit: 1c0aaf7dd27b5ed00a5319e0e0506287bd02f606 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=1c0aaf7dd27b5ed00a5319e0e…
Author: Huw Davies <huw(a)codeweavers.com> Date: Fri Feb 15 16:13:41 2013 +0000 riched20: Use ME_PointFromChar to calculate the caret position. --- dlls/riched20/caret.c | 12 +++--------- 1 files changed, 3 insertions(+), 9 deletions(-) diff --git a/dlls/riched20/caret.c b/dlls/riched20/caret.c index 4986f6e..76c169b 100644 --- a/dlls/riched20/caret.c +++ b/dlls/riched20/caret.c @@ -205,7 +205,7 @@ ME_GetCursorCoordinates(ME_TextEditor *editor, ME_Cursor *pCursor, ME_DisplayItem *para = pCursor->pPara; ME_DisplayItem *pSizeRun = run; ME_Context c; - SIZE sz = {0, 0}; + int run_x; assert(height && x && y); assert(~para->member.para.nFlags & MEPF_REWRAP); @@ -235,18 +235,12 @@ ME_GetCursorCoordinates(ME_TextEditor *editor, ME_Cursor *pCursor, pSizeRun = run = tmp; assert(run); assert(run->type == diRun); - sz = ME_GetRunSize(&c, ¶->member.para, - &run->member.run, run->member.run.len, - row->member.row.nLMargin); } } - if (pCursor->nOffset) { - sz = ME_GetRunSize(&c, ¶->member.para, &run->member.run, - pCursor->nOffset, row->member.row.nLMargin); - } + run_x = ME_PointFromCharContext( &c, &run->member.run, pCursor->nOffset ); *height = pSizeRun->member.run.nAscent + pSizeRun->member.run.nDescent; - *x = c.rcView.left + run->member.run.pt.x + sz.cx - editor->horz_si.nPos; + *x = c.rcView.left + run->member.run.pt.x + run_x - editor->horz_si.nPos; *y = c.rcView.top + para->member.para.pt.y + row->member.row.nBaseline + run->member.run.pt.y - pSizeRun->member.run.nAscent - editor->vert_si.nPos;
1
0
0
0
Huw Davies : riched20: Move the password string hack to just before it' s used.
by Alexandre Julliard
15 Feb '13
15 Feb '13
Module: wine Branch: master Commit: 635614b5ea9881bb9b922549b3cfb5f9bceee02c URL:
http://source.winehq.org/git/wine.git/?a=commit;h=635614b5ea9881bb9b922549b…
Author: Huw Davies <huw(a)codeweavers.com> Date: Fri Feb 15 16:13:40 2013 +0000 riched20: Move the password string hack to just before it's used. --- dlls/riched20/paint.c | 34 ++++++++++++++++------------------ 1 files changed, 16 insertions(+), 18 deletions(-) diff --git a/dlls/riched20/paint.c b/dlls/riched20/paint.c index 9937ec7..0ab4e2b 100644 --- a/dlls/riched20/paint.c +++ b/dlls/riched20/paint.c @@ -314,11 +314,19 @@ static void get_selection_rect( ME_Context *c, ME_Run *run, int from, int to, in } -static void draw_text( ME_Context *c, ME_Run *run, int x, int y, const WCHAR *text, BOOL selected, RECT *sel_rect ) +static void draw_text( ME_Context *c, ME_Run *run, int x, int y, BOOL selected, RECT *sel_rect ) { COLORREF text_color = get_text_color( c, run->style, selected ); COLORREF back_color = selected ? ITextHost_TxGetSysColor( c->editor->texthost, COLOR_HIGHLIGHT ) : 0; COLORREF old_text, old_back; + const WCHAR *text = get_text( run, 0 ); + ME_String *masked = NULL; + + if (c->editor->cPasswordMask) + { + masked = ME_MakeStringR( c->editor->cPasswordMask, run->len ); + text = masked->szData; + } old_text = SetTextColor( c->hDC, text_color ); if (selected) old_back = SetBkColor( c->hDC, back_color ); @@ -330,11 +338,12 @@ static void draw_text( ME_Context *c, ME_Run *run, int x, int y, const WCHAR *te draw_underline( c, run, x, y, text_color ); + ME_DestroyString( masked ); return; } -static void ME_DrawTextWithStyle(ME_Context *c, ME_Run *run, int x, int y, LPCWSTR szText, +static void ME_DrawTextWithStyle(ME_Context *c, ME_Run *run, int x, int y, int nSelFrom, int nSelTo, int ymin, int cy) { HDC hDC = c->hDC; @@ -373,12 +382,12 @@ static void ME_DrawTextWithStyle(ME_Context *c, ME_Run *run, int x, int y, LPCWS hOldFont = ME_SelectStyleFont( c, run->style ); if (sel_rgn) ExtSelectClipRgn( hDC, sel_rgn, RGN_DIFF ); - draw_text( c, run, x, y - yOffset, szText, FALSE, NULL ); + draw_text( c, run, x, y - yOffset, FALSE, NULL ); if (sel_rgn) { ExtSelectClipRgn( hDC, clip, RGN_COPY ); ExtSelectClipRgn( hDC, sel_rgn, RGN_AND ); - draw_text( c, run, x, y - yOffset, szText, TRUE, &sel_rect ); + draw_text( c, run, x, y - yOffset, TRUE, &sel_rect ); ExtSelectClipRgn( hDC, clip, RGN_COPY ); if (clip) DeleteObject( clip ); DeleteObject( sel_rgn ); @@ -439,20 +448,9 @@ static void ME_DrawRun(ME_Context *c, int x, int y, ME_DisplayItem *rundi, ME_Pa ME_DrawOLE(c, x, y, run, para, (runofs >= nSelFrom) && (runofs < nSelTo)); else { - if (c->editor->cPasswordMask) - { - ME_String *szMasked = ME_MakeStringR(c->editor->cPasswordMask, run->len); - ME_DrawTextWithStyle(c, run, x, y, - szMasked->szData, nSelFrom - runofs, nSelTo - runofs, - c->pt.y + para->pt.y + start->member.row.pt.y, - start->member.row.nHeight); - ME_DestroyString(szMasked); - } - else - ME_DrawTextWithStyle(c, run, x, y, - get_text( run, 0 ), nSelFrom - runofs, nSelTo - runofs, - c->pt.y + para->pt.y + start->member.row.pt.y, - start->member.row.nHeight); + ME_DrawTextWithStyle(c, run, x, y, nSelFrom - runofs, nSelTo - runofs, + c->pt.y + para->pt.y + start->member.row.pt.y, + start->member.row.nHeight); } }
1
0
0
0
Huw Davies : riched20: Move the range clamping to the helper now that the range isn' t used later on.
by Alexandre Julliard
15 Feb '13
15 Feb '13
Module: wine Branch: master Commit: a4378f44aa162c6e7984d2fe41dcabc990dadbe6 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=a4378f44aa162c6e7984d2fe4…
Author: Huw Davies <huw(a)codeweavers.com> Date: Fri Feb 15 16:13:39 2013 +0000 riched20: Move the range clamping to the helper now that the range isn't used later on. --- dlls/riched20/paint.c | 5 ++--- 1 files changed, 2 insertions(+), 3 deletions(-) diff --git a/dlls/riched20/paint.c b/dlls/riched20/paint.c index 06026df..9937ec7 100644 --- a/dlls/riched20/paint.c +++ b/dlls/riched20/paint.c @@ -304,7 +304,8 @@ static void draw_space( ME_Context *c, ME_Run *run, int x, int y, static void get_selection_rect( ME_Context *c, ME_Run *run, int from, int to, int cy, RECT *r ) { - + from = max( 0, from ); + to = min( run->len, to ); r->left = ME_PointFromCharContext( c, run, from ); r->top = 0; r->right = ME_PointFromCharContext( c, run, to ); @@ -349,8 +350,6 @@ static void ME_DrawTextWithStyle(ME_Context *c, ME_Run *run, int x, int y, LPCWS if (selected) { - nSelFrom = max( 0, nSelFrom ); - nSelTo = min( run->len, nSelTo ); get_selection_rect( c, run, nSelFrom, nSelTo, cy, &sel_rect ); OffsetRect( &sel_rect, x, ymin );
1
0
0
0
Huw Davies : riched20: Move underline drawing to a common function.
by Alexandre Julliard
15 Feb '13
15 Feb '13
Module: wine Branch: master Commit: 79278497d3095c4a0a6710c6065c169fefec067e URL:
http://source.winehq.org/git/wine.git/?a=commit;h=79278497d3095c4a0a6710c60…
Author: Huw Davies <huw(a)codeweavers.com> Date: Fri Feb 15 16:13:38 2013 +0000 riched20: Move underline drawing to a common function. --- dlls/riched20/paint.c | 38 ++++++++++++++++++-------------------- 1 files changed, 18 insertions(+), 20 deletions(-) diff --git a/dlls/riched20/paint.c b/dlls/riched20/paint.c index e4bd9e6..06026df 100644 --- a/dlls/riched20/paint.c +++ b/dlls/riched20/paint.c @@ -228,6 +228,22 @@ static void get_underline_pen( ME_Style *style, COLORREF color, HPEN *pen ) return; } +static void draw_underline( ME_Context *c, ME_Run *run, int x, int y, COLORREF color ) +{ + HPEN pen; + + get_underline_pen( run->style, color, &pen ); + if (pen) + { + HPEN old_pen = SelectObject( c->hDC, pen ); + MoveToEx( c->hDC, x, y + 1, NULL ); + LineTo( c->hDC, x + run->nWidth, y + 1 ); + SelectObject( c->hDC, old_pen ); + DeleteObject( pen ); + } + return; +} + /********************************************************************* * draw_space * @@ -260,7 +276,6 @@ static void draw_space( ME_Context *c, ME_Run *run, int x, int y, COLORREF text_color = get_text_color( c, run->style, selected ); COLORREF old_text, old_back; HFONT old_font = NULL; - HPEN pen = NULL; int y_offset = calc_y_offset( c, run->style ); static const WCHAR space[1] = {' '}; @@ -274,15 +289,7 @@ static void draw_space( ME_Context *c, ME_Run *run, int x, int y, SetTextColor( hdc, old_text ); ME_UnselectStyleFont( c, run->style, old_font ); - get_underline_pen( run->style, text_color, &pen ); - if (pen) - { - HPEN old_pen = SelectObject( hdc, pen ); - MoveToEx( hdc, x, y - y_offset + 1, NULL ); - LineTo( hdc, x + run->nWidth, y - y_offset + 1 ); - SelectObject( hdc, old_pen ); - DeleteObject( pen ); - } + draw_underline( c, run, x, y - y_offset, text_color ); } else if (selected) { @@ -311,7 +318,6 @@ static void draw_text( ME_Context *c, ME_Run *run, int x, int y, const WCHAR *te COLORREF text_color = get_text_color( c, run->style, selected ); COLORREF back_color = selected ? ITextHost_TxGetSysColor( c->editor->texthost, COLOR_HIGHLIGHT ) : 0; COLORREF old_text, old_back; - HPEN pen; old_text = SetTextColor( c->hDC, text_color ); if (selected) old_back = SetBkColor( c->hDC, back_color ); @@ -321,15 +327,7 @@ static void draw_text( ME_Context *c, ME_Run *run, int x, int y, const WCHAR *te if (selected) SetBkColor( c->hDC, old_back ); SetTextColor( c->hDC, old_text ); - get_underline_pen( run->style, text_color, &pen ); - if (pen) - { - HPEN old_pen = SelectObject( c->hDC, pen ); - MoveToEx( c->hDC, x, y + 1, NULL ); - LineTo( c->hDC, x + run->nWidth, y + 1 ); - SelectObject( c->hDC, old_pen ); - DeleteObject( pen ); - } + draw_underline( c, run, x, y, text_color ); return; }
1
0
0
0
Hans Leidekker : msi: Don' t remove products if msidbUpgradeAttributesOnlyDetect is set.
by Alexandre Julliard
15 Feb '13
15 Feb '13
Module: wine Branch: master Commit: bfe5e58d3a3e3e829fa1dd5a08c874dc8744bc0f URL:
http://source.winehq.org/git/wine.git/?a=commit;h=bfe5e58d3a3e3e829fa1dd5a0…
Author: Hans Leidekker <hans(a)codeweavers.com> Date: Fri Feb 15 16:45:04 2013 +0100 msi: Don't remove products if msidbUpgradeAttributesOnlyDetect is set. --- dlls/msi/action.c | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/dlls/msi/action.c b/dlls/msi/action.c index 5abe040..d48ecdd 100644 --- a/dlls/msi/action.c +++ b/dlls/msi/action.c @@ -7260,12 +7260,14 @@ static UINT ITERATE_RemoveExistingProducts( MSIRECORD *rec, LPVOID param ) {'m','s','i','e','x','e','c',' ','/','i',' ','%','s',' ','R','E','M','O','V','E','=','%','s',0}; MSIPACKAGE *package = param; const WCHAR *property = MSI_RecordGetString( rec, 7 ); + int attrs = MSI_RecordGetInteger( rec, 5 ); UINT len = sizeof(fmtW)/sizeof(fmtW[0]); WCHAR *product, *features, *cmd; STARTUPINFOW si; PROCESS_INFORMATION info; BOOL ret; + if (attrs & msidbUpgradeAttributesOnlyDetect) return ERROR_SUCCESS; if (!(product = msi_dup_property( package->db, property ))) return ERROR_SUCCESS; deformat_string( package, MSI_RecordGetString( rec, 6 ), &features );
1
0
0
0
Francois Gouget : winetest: Trace the time it takes to run each test.
by Alexandre Julliard
15 Feb '13
15 Feb '13
Module: wine Branch: master Commit: f704803c96d0f789f947d2de6ad0189f59f5fa8b URL:
http://source.winehq.org/git/wine.git/?a=commit;h=f704803c96d0f789f947d2de6…
Author: Francois Gouget <fgouget(a)codeweavers.com> Date: Fri Feb 15 11:16:49 2013 +0100 winetest: Trace the time it takes to run each test. --- programs/winetest/main.c | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/programs/winetest/main.c b/programs/winetest/main.c index 427b6b4..6c8e327 100644 --- a/programs/winetest/main.c +++ b/programs/winetest/main.c @@ -724,12 +724,13 @@ run_test (struct wine_test* test, const char* subtest, HANDLE out_file, const ch else { int status; + DWORD start = GetTickCount(); char *cmd = strmake (NULL, "%s %s", test->exename, subtest); report (R_STEP, "Running: %s:%s", test->name, subtest); xprintf ("%s:%s start %s -\n", test->name, subtest, file); status = run_ex (cmd, out_file, tempdir, 120000); heap_free (cmd); - xprintf ("%s:%s done (%d)\n", test->name, subtest, status); + xprintf ("%s:%s done (%d) in %ds\n", test->name, subtest, status, (GetTickCount()-start)/1000); if (status) failures++; } if (failures) report (R_STATUS, "Running tests - %u failures", failures);
1
0
0
0
Piotr Caban : vbscript: Rename vbsheap to heap_pool.
by Alexandre Julliard
15 Feb '13
15 Feb '13
Module: wine Branch: master Commit: fb29bf7d2f04607b0a8e74b2b35f7aa2cda9ebdc URL:
http://source.winehq.org/git/wine.git/?a=commit;h=fb29bf7d2f04607b0a8e74b2b…
Author: Piotr Caban <piotr(a)codeweavers.com> Date: Fri Feb 15 15:11:13 2013 +0100 vbscript: Rename vbsheap to heap_pool. --- dlls/vbscript/compile.c | 8 ++++---- dlls/vbscript/interp.c | 12 ++++++------ dlls/vbscript/parse.h | 2 +- dlls/vbscript/parser.y | 6 +++--- dlls/vbscript/vbscript.c | 6 +++--- dlls/vbscript/vbscript.h | 12 ++++++------ dlls/vbscript/vbscript_main.c | 6 +++--- 7 files changed, 26 insertions(+), 26 deletions(-) diff --git a/dlls/vbscript/compile.c b/dlls/vbscript/compile.c index d324284..58494b9 100644 --- a/dlls/vbscript/compile.c +++ b/dlls/vbscript/compile.c @@ -118,14 +118,14 @@ static void dump_code(compile_ctx_t *ctx) static inline void *compiler_alloc(vbscode_t *vbscode, size_t size) { - return vbsheap_alloc(&vbscode->heap, size); + return heap_pool_alloc(&vbscode->heap, size); } static inline void *compiler_alloc_zero(vbscode_t *vbscode, size_t size) { void *ret; - ret = vbsheap_alloc(&vbscode->heap, size); + ret = heap_pool_alloc(&vbscode->heap, size); if(ret) memset(ret, 0, size); return ret; @@ -1585,7 +1585,7 @@ void release_vbscode(vbscode_t *code) for(i=0; i < code->bstr_cnt; i++) SysFreeString(code->bstr_pool[i]); - vbsheap_free(&code->heap); + heap_pool_free(&code->heap); heap_free(code->bstr_pool); heap_free(code->source); @@ -1615,7 +1615,7 @@ static vbscode_t *alloc_vbscode(compile_ctx_t *ctx, const WCHAR *source) ctx->instr_cnt = 1; ctx->instr_size = 32; - vbsheap_init(&ret->heap); + heap_pool_init(&ret->heap); ret->option_explicit = ctx->parser.option_explicit; diff --git a/dlls/vbscript/interp.c b/dlls/vbscript/interp.c index eace041..b3f4244 100644 --- a/dlls/vbscript/interp.c +++ b/dlls/vbscript/interp.c @@ -37,7 +37,7 @@ typedef struct { VARIANT *vars; dynamic_var_t *dynamic_vars; - vbsheap_t heap; + heap_pool_t heap; BOOL resume_next; @@ -210,19 +210,19 @@ static HRESULT add_dynamic_var(exec_ctx_t *ctx, const WCHAR *name, BOOL is_const, VARIANT *val, BOOL own_val, VARIANT **out_var) { dynamic_var_t *new_var; - vbsheap_t *heap; + heap_pool_t *heap; WCHAR *str; unsigned size; HRESULT hres; heap = ctx->func->type == FUNC_GLOBAL ? &ctx->script->heap : &ctx->heap; - new_var = vbsheap_alloc(heap, sizeof(*new_var)); + new_var = heap_pool_alloc(heap, sizeof(*new_var)); if(!new_var) return E_OUTOFMEMORY; size = (strlenW(name)+1)*sizeof(WCHAR); - str = vbsheap_alloc(heap, size); + str = heap_pool_alloc(heap, size); if(!str) return E_OUTOFMEMORY; memcpy(str, name, size); @@ -1833,7 +1833,7 @@ static void release_exec(exec_ctx_t *ctx) VariantClear(ctx->vars+i); } - vbsheap_free(&ctx->heap); + heap_pool_free(&ctx->heap); heap_free(ctx->args); heap_free(ctx->vars); heap_free(ctx->stack); @@ -1852,7 +1852,7 @@ HRESULT exec_script(script_ctx_t *ctx, function_t *func, IDispatch *this_obj, DI return E_FAIL; } - vbsheap_init(&exec.heap); + heap_pool_init(&exec.heap); if(func->arg_cnt) { VARIANT *v; diff --git a/dlls/vbscript/parse.h b/dlls/vbscript/parse.h index 74e0a8a..ba1a311 100644 --- a/dlls/vbscript/parse.h +++ b/dlls/vbscript/parse.h @@ -263,7 +263,7 @@ typedef struct { statement_t *stats_tail; class_decl_t *class_decls; - vbsheap_t heap; + heap_pool_t heap; } parser_ctx_t; HRESULT parse_script(parser_ctx_t*,const WCHAR*,const WCHAR*) DECLSPEC_HIDDEN; diff --git a/dlls/vbscript/parser.y b/dlls/vbscript/parser.y index b71b92d..4b380ef 100644 --- a/dlls/vbscript/parser.y +++ b/dlls/vbscript/parser.y @@ -922,7 +922,7 @@ void *parser_alloc(parser_ctx_t *ctx, size_t size) { void *ret; - ret = vbsheap_alloc(&ctx->heap, size); + ret = heap_pool_alloc(&ctx->heap, size); if(!ret) ctx->hres = E_OUTOFMEMORY; return ret; @@ -935,7 +935,7 @@ HRESULT parse_script(parser_ctx_t *ctx, const WCHAR *code, const WCHAR *delimite ctx->code = ctx->ptr = code; ctx->end = ctx->code + strlenW(ctx->code); - vbsheap_init(&ctx->heap); + heap_pool_init(&ctx->heap); ctx->parse_complete = FALSE; ctx->hres = S_OK; @@ -961,5 +961,5 @@ HRESULT parse_script(parser_ctx_t *ctx, const WCHAR *code, const WCHAR *delimite void parser_release(parser_ctx_t *ctx) { - vbsheap_free(&ctx->heap); + heap_pool_free(&ctx->heap); } diff --git a/dlls/vbscript/vbscript.c b/dlls/vbscript/vbscript.c index 1195f85..48dd18c 100644 --- a/dlls/vbscript/vbscript.c +++ b/dlls/vbscript/vbscript.c @@ -172,8 +172,8 @@ static void release_script(script_ctx_t *ctx) IDispatchEx_Release(&script_obj->IDispatchEx_iface); } - vbsheap_free(&ctx->heap); - vbsheap_init(&ctx->heap); + heap_pool_free(&ctx->heap); + heap_pool_init(&ctx->heap); } static void destroy_script(script_ctx_t *ctx) @@ -568,7 +568,7 @@ static HRESULT WINAPI VBScriptParse_InitNew(IActiveScriptParse *iface) return E_OUTOFMEMORY; ctx->safeopt = This->safeopt; - vbsheap_init(&ctx->heap); + heap_pool_init(&ctx->heap); list_init(&ctx->objects); list_init(&ctx->code_list); list_init(&ctx->named_items); diff --git a/dlls/vbscript/vbscript.h b/dlls/vbscript/vbscript.h index e3d96d8..f499e4f 100644 --- a/dlls/vbscript/vbscript.h +++ b/dlls/vbscript/vbscript.h @@ -37,11 +37,11 @@ typedef struct { DWORD last_block; DWORD offset; struct list custom_blocks; -} vbsheap_t; +} heap_pool_t; -void vbsheap_init(vbsheap_t*) DECLSPEC_HIDDEN; -void *vbsheap_alloc(vbsheap_t*,size_t) __WINE_ALLOC_SIZE(2) DECLSPEC_HIDDEN; -void vbsheap_free(vbsheap_t*) DECLSPEC_HIDDEN; +void heap_pool_init(heap_pool_t*) DECLSPEC_HIDDEN; +void *heap_pool_alloc(heap_pool_t*,size_t) __WINE_ALLOC_SIZE(2) DECLSPEC_HIDDEN; +void heap_pool_free(heap_pool_t*) DECLSPEC_HIDDEN; typedef struct _function_t function_t; typedef struct _vbscode_t vbscode_t; @@ -177,7 +177,7 @@ struct _script_ctx_t { class_desc_t *classes; class_desc_t *procs; - vbsheap_t heap; + heap_pool_t heap; struct list objects; struct list code_list; @@ -320,7 +320,7 @@ struct _vbscode_t { BSTR *bstr_pool; unsigned bstr_pool_size; unsigned bstr_cnt; - vbsheap_t heap; + heap_pool_t heap; struct list entry; }; diff --git a/dlls/vbscript/vbscript_main.c b/dlls/vbscript/vbscript_main.c index 9ff2a51..a06eb2c 100644 --- a/dlls/vbscript/vbscript_main.c +++ b/dlls/vbscript/vbscript_main.c @@ -133,13 +133,13 @@ static inline DWORD block_size(DWORD block) return MIN_BLOCK_SIZE << block; } -void vbsheap_init(vbsheap_t *heap) +void heap_pool_init(heap_pool_t *heap) { memset(heap, 0, sizeof(*heap)); list_init(&heap->custom_blocks); } -void *vbsheap_alloc(vbsheap_t *heap, size_t size) +void *heap_pool_alloc(heap_pool_t *heap, size_t size) { struct list *list; void *tmp; @@ -194,7 +194,7 @@ void *vbsheap_alloc(vbsheap_t *heap, size_t size) return list+1; } -void vbsheap_free(vbsheap_t *heap) +void heap_pool_free(heap_pool_t *heap) { struct list *iter; DWORD i;
1
0
0
0
Piotr Caban : vbscript: Added IRegExp2::Pattern implementation.
by Alexandre Julliard
15 Feb '13
15 Feb '13
Module: wine Branch: master Commit: 7246f7f3aa97ef5e0a6554846fe600d309bb61f4 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=7246f7f3aa97ef5e0a6554846…
Author: Piotr Caban <piotr(a)codeweavers.com> Date: Fri Feb 15 15:10:53 2013 +0100 vbscript: Added IRegExp2::Pattern implementation. --- dlls/vbscript/vbregexp.c | 40 ++++++++++++++++++++++++++++++++++++---- 1 files changed, 36 insertions(+), 4 deletions(-) diff --git a/dlls/vbscript/vbregexp.c b/dlls/vbscript/vbregexp.c index 1afe44b..ffd110d 100644 --- a/dlls/vbscript/vbregexp.c +++ b/dlls/vbscript/vbregexp.c @@ -84,6 +84,8 @@ typedef struct { IRegExp IRegExp_iface; LONG ref; + + WCHAR *pattern; } RegExp2; static inline RegExp2 *impl_from_IRegExp2(IRegExp2 *iface) @@ -135,6 +137,7 @@ static ULONG WINAPI RegExp2_Release(IRegExp2 *iface) TRACE("(%p) ref=%d\n", This, ref); if(!ref) { + heap_free(This->pattern); heap_free(This); } @@ -186,15 +189,44 @@ static HRESULT WINAPI RegExp2_Invoke(IRegExp2 *iface, DISPID dispIdMember, static HRESULT WINAPI RegExp2_get_Pattern(IRegExp2 *iface, BSTR *pPattern) { RegExp2 *This = impl_from_IRegExp2(iface); - FIXME("(%p)->(%p)\n", This, pPattern); - return E_NOTIMPL; + + TRACE("(%p)->(%p)\n", This, pPattern); + + if(!pPattern) + return E_POINTER; + + if(!This->pattern) { + *pPattern = NULL; + return S_OK; + } + + *pPattern = SysAllocString(This->pattern); + return *pPattern ? S_OK : E_OUTOFMEMORY; } static HRESULT WINAPI RegExp2_put_Pattern(IRegExp2 *iface, BSTR pattern) { RegExp2 *This = impl_from_IRegExp2(iface); - FIXME("(%p)->(%s)\n", This, wine_dbgstr_w(pattern)); - return E_NOTIMPL; + WCHAR *p; + DWORD size; + + TRACE("(%p)->(%s)\n", This, wine_dbgstr_w(pattern)); + + if(!pattern) { + heap_free(This->pattern); + This->pattern = NULL; + return S_OK; + } + + size = (SysStringLen(pattern)+1) * sizeof(WCHAR); + p = heap_alloc(size); + if(!p) + return E_OUTOFMEMORY; + + heap_free(This->pattern); + This->pattern = p; + memcpy(p, pattern, size); + return S_OK; } static HRESULT WINAPI RegExp2_get_IgnoreCase(IRegExp2 *iface, VARIANT_BOOL *pIgnoreCase)
1
0
0
0
← Newer
1
...
21
22
23
24
25
26
27
...
46
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
Results per page:
10
25
50
100
200