/* Free a block of memory allocated by `mmalloc'. */
-/* Copyright (c) 2010-2022. The SimGrid Team. All rights reserved. */
+/* Copyright (c) 2010-2023. The SimGrid Team. All rights reserved. */
/* This program is free software; you can redistribute it and/or modify it
* under the terms of the license (GNU LGPL) which comes with this package. */
Heavily modified Mar 1992 by Fred Fish. (fnf@cygnus.com) */
#include "mmprivate.h"
-#include "mc/mc.h"
+#include "src/mc/mc.h"
/* Return memory to the heap.
Like `mfree' but don't call a mfree_hook if there is one. */
{
size_t frag_nb;
size_t i;
- int it;
+ size_t it;
if (ptr == NULL)
return;
for (it=0; it<mdp->heapinfo[block].busy_block.size; it++) {
if (mdp->heapinfo[block+it].type < 0) {
fprintf(stderr,
- "Internal Error: Asked to free a block already marked as free (block=%zu it=%d type=%d). "
+ "Internal Error: Asked to free a block already marked as free (block=%zu it=%zu type=%d). "
"Please report this bug.\n",
block, it, mdp->heapinfo[block].type);
abort();
for (it=0; it<mdp->heapinfo[block].free_block.size; it++) {
if (mdp->heapinfo[block+it].type <0) {
fprintf(stderr,
- "Internal error: Asked to free a block already marked as free (block=%zu it=%d/%zu type=%d). "
+ "Internal error: Asked to free a block already marked as free (block=%zu it=%zu/%zu type=%d). "
"Please report this bug.\n",
block, it, mdp->heapinfo[block].free_block.size, mdp->heapinfo[block].type);
abort();