|
From: Carlo W. <li...@us...> - 2001-12-31 05:01:35
|
CVSROOT : /cvsroot/libcw
Module : src
Commit time: 2001-11-31 05:01:34 UTC
Modified files:
libcwd/bfd.cc
Log message:
Don't start ST_exec_prog with 'internal' on.
---------------------- diff included ----------------------
Index: src/libcwd/bfd.cc
diff -u src/libcwd/bfd.cc:1.89 src/libcwd/bfd.cc:1.90
--- src/libcwd/bfd.cc:1.89 Sun Dec 30 13:18:16 2001
+++ src/libcwd/bfd.cc Sun Dec 30 21:01:23 2001
@@ -1,4 +1,4 @@
-// $Header: /cvsroot/l/li/libcw/src/libcwd/bfd.cc,v 1.89 2001/12/30 21:18:16 libcw Exp $
+// $Header: /cvsroot/l/li/libcw/src/libcwd/bfd.cc,v 1.90 2001/12/31 05:01:23 libcw Exp $
//
// Copyright (C) 2000 - 2001, by
//
@@ -835,7 +835,7 @@
};
// cwbfd::
- typedef _private_::internal_vector<my_link_map> ST_shared_libs_vector_ct;
+ typedef std::vector<my_link_map> ST_shared_libs_vector_ct;
ST_shared_libs_vector_ct ST_shared_libs; // Written to only in `ST_decode_ldd' which is called from
// `cwbfd::ST_init' and read from in a later part of `cwbfd::ST_init'.
@@ -942,13 +942,7 @@
LIBCWD_TSD_DECLARATION
#if defined(DEBUGDEBUG) && defined(DEBUGMALLOC)
- // First time we get here, this string is intialized - this must be with `internal' off!
- static bool second_time = false;
- if (!second_time)
- {
- second_time = true;
- LIBCWD_ASSERT( !__libcwd_tsd.internal );
- }
+ LIBCWD_ASSERT( !__libcwd_tsd.internal );
#endif
// ****************************************************************************
@@ -1031,13 +1025,15 @@
argv[0] = "ldd";
argv[1] = fullpath.value->data();
argv[2] = NULL;
+ set_alloc_checking_on(LIBCWD_TSD);
ST_exec_prog(ldd_prog, argv, environ, ST_decode_ldd);
+ set_alloc_checking_off(LIBCWD_TSD);
- for(ST_shared_libs_vector_ct::iterator iter = ST_shared_libs.begin(); iter != ST_shared_libs.end(); ++iter)
+ for(ST_shared_libs_vector_ct::const_iterator iter = ST_shared_libs.begin(); iter != ST_shared_libs.end(); ++iter)
{
- my_link_map* l = &(*iter);
+ my_link_map const* l = &(*iter);
#else
- for(link_map* l = _dl_loaded; l; l = l->l_next)
+ for(link_map const* l = _dl_loaded; l; l = l->l_next)
{
#endif
if (l->l_addr)
----------------------- End of diff -----------------------
|