<html>
<head>
<style>
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:Verdana
}
</style>
</head>
<body class='hmmessage'>
<BR>
Hi, ITKers,<BR>
<BR>
I have a smart pointer problem.<BR>
Here is my code:<BR>
///////////////////////////////<BR>
<BR>
#include ""<BR>
<BR>
typedef itk::XXXX <> FilterType<BR>
FilterType filter = FilterType::New();<BR>
<BR>
int main()<BR>
{<BR>
..........................<BR>
filter->Update();<BR>
funa();<BR>
..........................<BR>
}<BR>
void funa()<BR>
{<BR>
.................<BR>
filter->update();<BR>
..................<BR>
}<BR>
//////////////////////////////////////<BR>
The program will throw out an exception about filter garbage collection.<BR>
How to fix this exception without passing the filter as a parameter to funa?<BR>
<BR>
Any input will be appreciated.<BR>
Siqi<RTE_TEXT></RTE_TEXT><BR><br /><hr />使用新一代 Windows Live Messenger 轻松交流和共享! <a href='http://im.live.cn/' target='_new'>立刻下载!</a></body>
</html>