summaryrefslogtreecommitdiff
path: root/TAO/TAO_IDL/util/utl_stack.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'TAO/TAO_IDL/util/utl_stack.cpp')
-rw-r--r--TAO/TAO_IDL/util/utl_stack.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/TAO/TAO_IDL/util/utl_stack.cpp b/TAO/TAO_IDL/util/utl_stack.cpp
index aac41c094af..70c0168fe62 100644
--- a/TAO/TAO_IDL/util/utl_stack.cpp
+++ b/TAO/TAO_IDL/util/utl_stack.cpp
@@ -129,9 +129,11 @@ UTL_ScopeStack::pop (void)
return;
}
+ UTL_Scope *current = this->top ();
+
// If our top scope has a #pragma prefix associated with it,
// it goes away with the scope.
- if (this->top_non_null ()->has_prefix ())
+ if (current != 0 && current->has_prefix ())
{
char *trash = 0;
idl_global->pragma_prefixes ().pop (trash);