New source tree.
[cacao.git] / src / mm / memory.c
index 2a6673189726a69d71d83cd42cf665c7ec8212ed..85ea79ea85b5c600f6b2f3470ca50e6020090125 100644 (file)
@@ -26,7 +26,7 @@
 
    Authors: Reinhard Grafl
 
-   $Id: memory.c 1568 2004-11-23 16:02:31Z twisti $
+   $Id: memory.c 1621 2004-11-30 13:06:55Z twisti $
 
 */
 
 #include <unistd.h>
 
 #include "config.h"
-#include "exceptions.h"
-#include "global.h"
-#include "native.h"
-#include "options.h"
-#include "statistics.h"
-#include "threads/nativethread.h"
+#include "mm/memory.h"
+#include "vm/exceptions.h"
+#include "vm/global.h"
+#include "vm/options.h"
+#include "vm/statistics.h"
+#include "native/native.h"
+
+#if defined(USE_THREADS) && defined(NATIVE_THREADS)
+# include "threads/native/threads.h"
+#endif
+
 #include "toolbox/logging.h"
-#include "toolbox/memory.h"
 
 
 /********* general types, variables and auxiliary functions *********/
@@ -321,6 +325,9 @@ s4 dump_size()
        di = &nothreads_dumpinfo;
 #endif
 
+       if (!di)
+               return 0;
+
        return di->useddumpsize;
 }