Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
dragonwell8_jdk
提交
37017e11
D
dragonwell8_jdk
项目概览
openanolis
/
dragonwell8_jdk
通知
4
Star
2
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
D
dragonwell8_jdk
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
37017e11
编写于
4月 27, 2011
作者:
D
denis
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
6998716: client vm crashes making browser fails to respond under some scenarios
Reviewed-by: art, denis, uta
上级
f405652e
变更
10
隐藏空白更改
内联
并排
Showing
10 changed file
with
51 addition
and
24 deletion
+51
-24
src/windows/native/sun/windows/ObjectList.cpp
src/windows/native/sun/windows/ObjectList.cpp
+5
-2
src/windows/native/sun/windows/ObjectList.h
src/windows/native/sun/windows/ObjectList.h
+1
-1
src/windows/native/sun/windows/awt_Component.cpp
src/windows/native/sun/windows/awt_Component.cpp
+4
-3
src/windows/native/sun/windows/awt_MenuItem.cpp
src/windows/native/sun/windows/awt_MenuItem.cpp
+1
-2
src/windows/native/sun/windows/awt_Object.cpp
src/windows/native/sun/windows/awt_Object.cpp
+12
-7
src/windows/native/sun/windows/awt_Object.h
src/windows/native/sun/windows/awt_Object.h
+4
-0
src/windows/native/sun/windows/awt_Robot.cpp
src/windows/native/sun/windows/awt_Robot.cpp
+1
-2
src/windows/native/sun/windows/awt_Toolkit.cpp
src/windows/native/sun/windows/awt_Toolkit.cpp
+21
-5
src/windows/native/sun/windows/awt_TrayIcon.cpp
src/windows/native/sun/windows/awt_TrayIcon.cpp
+1
-2
src/windows/native/sun/windows/awtmsg.h
src/windows/native/sun/windows/awtmsg.h
+1
-0
未找到文件。
src/windows/native/sun/windows/ObjectList.cpp
浏览文件 @
37017e11
...
@@ -48,7 +48,7 @@ void AwtObjectList::Add(AwtObject* obj)
...
@@ -48,7 +48,7 @@ void AwtObjectList::Add(AwtObject* obj)
m_head
=
item
;
m_head
=
item
;
}
}
void
AwtObjectList
::
Remove
(
AwtObject
*
obj
)
BOOL
AwtObjectList
::
Remove
(
AwtObject
*
obj
)
{
{
CriticalSection
::
Lock
l
(
m_lock
);
CriticalSection
::
Lock
l
(
m_lock
);
...
@@ -64,11 +64,14 @@ void AwtObjectList::Remove(AwtObject* obj)
...
@@ -64,11 +64,14 @@ void AwtObjectList::Remove(AwtObject* obj)
}
}
DASSERT
(
item
!=
NULL
);
DASSERT
(
item
!=
NULL
);
delete
item
;
delete
item
;
return
;
return
TRUE
;
}
}
lastItem
=
item
;
lastItem
=
item
;
item
=
item
->
next
;
item
=
item
->
next
;
}
}
return
FALSE
;
// DASSERT(FALSE); // should never get here...
// DASSERT(FALSE); // should never get here...
// even if it does it shouldn't be fatal.
// even if it does it shouldn't be fatal.
}
}
...
...
src/windows/native/sun/windows/ObjectList.h
浏览文件 @
37017e11
...
@@ -46,7 +46,7 @@ public:
...
@@ -46,7 +46,7 @@ public:
AwtObjectList
();
AwtObjectList
();
void
Add
(
AwtObject
*
obj
);
void
Add
(
AwtObject
*
obj
);
void
Remove
(
AwtObject
*
obj
);
BOOL
Remove
(
AwtObject
*
obj
);
#ifdef DEBUG
#ifdef DEBUG
/* Used for sanity checks only. */
/* Used for sanity checks only. */
AwtObject
*
LookUp
(
AwtObject
*
obj
);
AwtObject
*
LookUp
(
AwtObject
*
obj
);
...
...
src/windows/native/sun/windows/awt_Component.cpp
浏览文件 @
37017e11
...
@@ -1969,7 +1969,9 @@ MsgRouting AwtComponent::WmDestroy()
...
@@ -1969,7 +1969,9 @@ MsgRouting AwtComponent::WmDestroy()
{
{
// fix for 6259348: we should enter the SyncCall critical section before
// fix for 6259348: we should enter the SyncCall critical section before
// disposing the native object, that is value 1 of lParam is intended for
// disposing the native object, that is value 1 of lParam is intended for
AwtToolkit
::
GetInstance
().
SendMessage
(
WM_AWT_DISPOSE
,
(
WPARAM
)
this
,
(
LPARAM
)
1
);
if
(
m_peerObject
!=
NULL
)
{
// is not being terminating
AwtToolkit
::
GetInstance
().
SendMessage
(
WM_AWT_DISPOSE
,
(
WPARAM
)
m_peerObject
,
(
LPARAM
)
1
);
}
return
mrConsume
;
return
mrConsume
;
}
}
...
@@ -6534,8 +6536,7 @@ Java_sun_awt_windows_WComponentPeer__1dispose(JNIEnv *env, jobject self)
...
@@ -6534,8 +6536,7 @@ Java_sun_awt_windows_WComponentPeer__1dispose(JNIEnv *env, jobject self)
{
{
TRY_NO_HANG
;
TRY_NO_HANG
;
PDATA
pData
=
JNI_GET_PDATA
(
self
);
AwtObject
::
_Dispose
(
self
);
AwtObject
::
_Dispose
(
pData
);
CATCH_BAD_ALLOC
;
CATCH_BAD_ALLOC
;
}
}
...
...
src/windows/native/sun/windows/awt_MenuItem.cpp
浏览文件 @
37017e11
...
@@ -974,8 +974,7 @@ Java_sun_awt_windows_WMenuItemPeer__1dispose(JNIEnv *env, jobject self)
...
@@ -974,8 +974,7 @@ Java_sun_awt_windows_WMenuItemPeer__1dispose(JNIEnv *env, jobject self)
{
{
TRY_NO_HANG
;
TRY_NO_HANG
;
PDATA
pData
=
JNI_GET_PDATA
(
self
);
AwtObject
::
_Dispose
(
self
);
AwtObject
::
_Dispose
(
pData
);
CATCH_BAD_ALLOC
;
CATCH_BAD_ALLOC
;
}
}
...
...
src/windows/native/sun/windows/awt_Object.cpp
浏览文件 @
37017e11
...
@@ -60,11 +60,20 @@ AwtObject::~AwtObject()
...
@@ -60,11 +60,20 @@ AwtObject::~AwtObject()
void
AwtObject
::
Dispose
()
void
AwtObject
::
Dispose
()
{
{
theAwtObjectList
.
Remove
(
this
);
AwtToolkit
::
GetInstance
().
PostMessage
(
WM_AWT_DELETEOBJECT
,
(
WPARAM
)
this
,
(
LPARAM
)
0
);
}
void
AwtObject
::
_Dispose
(
jobject
self
)
{
TRY_NO_VERIFY
;
CriticalSection
::
Lock
l
(
AwtToolkit
::
GetInstance
().
GetSyncCS
());
// value 0 of lParam means that we should not attempt to enter the
// value 0 of lParam means that we should not attempt to enter the
// SyncCall critical section, as it was entered someshere earlier
// SyncCall critical section, as it was entered someshere earlier
AwtToolkit
::
GetInstance
().
PostMessage
(
WM_AWT_DELETEOBJECT
,
(
WPARAM
)
this
,
(
LPARAM
)
0
);
AwtToolkit
::
GetInstance
().
SendMessage
(
WM_AWT_DISPOSE
,
(
WPARAM
)
self
,
(
LPARAM
)
0
);
CATCH_BAD_ALLOC
;
}
}
void
AwtObject
::
_Dispose
(
PDATA
pData
)
void
AwtObject
::
_Dispose
(
PDATA
pData
)
...
@@ -73,14 +82,10 @@ void AwtObject::_Dispose(PDATA pData)
...
@@ -73,14 +82,10 @@ void AwtObject::_Dispose(PDATA pData)
CriticalSection
::
Lock
l
(
AwtToolkit
::
GetInstance
().
GetSyncCS
());
CriticalSection
::
Lock
l
(
AwtToolkit
::
GetInstance
().
GetSyncCS
());
if
(
pData
!=
NULL
)
{
AwtToolkit
::
GetInstance
().
SendMessage
(
WM_AWT_DISPOSEPDATA
,
(
WPARAM
)
pData
,
(
LPARAM
)
0
);
AwtObject
*
o
=
(
AwtObject
*
)
pData
;
AwtToolkit
::
GetInstance
().
SendMessage
(
WM_AWT_DISPOSE
,
(
WPARAM
)
o
,
(
LPARAM
)
0
);
}
CATCH_BAD_ALLOC
;
CATCH_BAD_ALLOC
;
}
}
/*
/*
* Return the peer associated with some target. This information is
* Return the peer associated with some target. This information is
* maintained in a hashtable at the java level.
* maintained in a hashtable at the java level.
...
...
src/windows/native/sun/windows/awt_Object.h
浏览文件 @
37017e11
...
@@ -66,6 +66,10 @@ public:
...
@@ -66,6 +66,10 @@ public:
// After this method has been called, this object must not be used in any way.
// After this method has been called, this object must not be used in any way.
virtual
void
Dispose
();
virtual
void
Dispose
();
// Static method to be called from JNI methods to dispose AwtObject
// specified by jobject
static
void
_Dispose
(
jobject
self
);
// Static method to be called from JNI methods to dispose AwtObject
// Static method to be called from JNI methods to dispose AwtObject
// specified by pData
// specified by pData
static
void
_Dispose
(
PDATA
pData
);
static
void
_Dispose
(
PDATA
pData
);
...
...
src/windows/native/sun/windows/awt_Robot.cpp
浏览文件 @
37017e11
...
@@ -353,8 +353,7 @@ JNIEXPORT void JNICALL Java_sun_awt_windows_WRobotPeer__1dispose(
...
@@ -353,8 +353,7 @@ JNIEXPORT void JNICALL Java_sun_awt_windows_WRobotPeer__1dispose(
{
{
TRY_NO_VERIFY
;
TRY_NO_VERIFY
;
PDATA
pData
=
JNI_GET_PDATA
(
self
);
AwtObject
::
_Dispose
(
self
);
AwtObject
::
_Dispose
(
pData
);
CATCH_BAD_ALLOC
;
CATCH_BAD_ALLOC
;
}
}
...
...
src/windows/native/sun/windows/awt_Toolkit.cpp
浏览文件 @
37017e11
...
@@ -740,18 +740,34 @@ LRESULT CALLBACK AwtToolkit::WndProc(HWND hWnd, UINT message,
...
@@ -740,18 +740,34 @@ LRESULT CALLBACK AwtToolkit::WndProc(HWND hWnd, UINT message,
canDispose
=
syncCS
.
TryEnter
();
canDispose
=
syncCS
.
TryEnter
();
}
}
if
(
canDispose
)
{
if
(
canDispose
)
{
AwtObject
*
o
=
(
AwtObject
*
)
wParam
;
if
(
wParam
!=
NULL
)
{
o
->
Dispose
();
AwtObject
*
o
=
(
AwtObject
*
)
JNI_GET_PDATA
((
jobject
)
wParam
);
if
(
shouldEnterCriticalSection
)
{
if
(
o
!=
NULL
&&
theAwtObjectList
.
Remove
(
o
))
{
syncCS
.
Leave
();
o
->
Dispose
();
}
if
(
shouldEnterCriticalSection
)
{
syncCS
.
Leave
();
}
}
}
}
else
{
}
else
{
AwtToolkit
::
GetInstance
().
PostMessage
(
WM_AWT_DISPOSE
,
wParam
,
lParam
);
AwtToolkit
::
GetInstance
().
PostMessage
(
WM_AWT_DISPOSE
,
wParam
,
lParam
);
}
}
return
0
;
return
0
;
}
}
case
WM_AWT_DISPOSEPDATA
:
{
/*
* NOTE: synchronization routine (like in WM_AWT_DISPOSE) was omitted because
* this handler is called ONLY while disposing Cursor and Font objects where
* synchronization takes place.
*/
AwtObject
*
o
=
(
AwtObject
*
)
wParam
;
if
(
o
!=
NULL
&&
theAwtObjectList
.
Remove
(
o
))
{
o
->
Dispose
();
}
return
0
;
}
case
WM_AWT_DELETEOBJECT
:
{
case
WM_AWT_DELETEOBJECT
:
{
AwtObject
*
p
=
(
AwtObject
*
)
wParam
;
AwtObject
*
p
=
(
AwtObject
*
)
wParam
;
if
(
p
->
CanBeDeleted
())
{
if
(
p
->
CanBeDeleted
())
{
// all the messages for this component are processed, so
// all the messages for this component are processed, so
// it can be deleted
// it can be deleted
...
...
src/windows/native/sun/windows/awt_TrayIcon.cpp
浏览文件 @
37017e11
...
@@ -926,8 +926,7 @@ Java_sun_awt_windows_WTrayIconPeer__1dispose(JNIEnv *env, jobject self)
...
@@ -926,8 +926,7 @@ Java_sun_awt_windows_WTrayIconPeer__1dispose(JNIEnv *env, jobject self)
{
{
TRY
;
TRY
;
PDATA
pData
=
JNI_GET_PDATA
(
self
);
AwtObject
::
_Dispose
(
self
);
AwtObject
::
_Dispose
(
pData
);
CATCH_BAD_ALLOC
;
CATCH_BAD_ALLOC
;
}
}
...
...
src/windows/native/sun/windows/awtmsg.h
浏览文件 @
37017e11
...
@@ -219,6 +219,7 @@ enum {
...
@@ -219,6 +219,7 @@ enum {
WM_AWT_ENDCOMPOSITION
,
WM_AWT_ENDCOMPOSITION
,
WM_AWT_DISPOSE
,
WM_AWT_DISPOSE
,
WM_AWT_DISPOSEPDATA
,
WM_AWT_DELETEOBJECT
,
WM_AWT_DELETEOBJECT
,
WM_AWT_SETCONVERSIONSTATUS
,
WM_AWT_SETCONVERSIONSTATUS
,
WM_AWT_GETCONVERSIONSTATUS
,
WM_AWT_GETCONVERSIONSTATUS
,
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录