+/* Copyright (c) 2005-2010, 2012-2015. 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. */
/*
* snprintf.c - a portable implementation of snprintf
#define LINUX_COMPATIBLE
#endif
-#include "portable.h" /* to get a working stdarg.h */
+#include "src/portable.h" /* to get a working stdarg.h */
#include <sys/types.h>
#include <string.h>
#endif
#define fast_memcpy(d,s,n) \
- { register size_t nn = (size_t)(n); \
+ { size_t nn = (size_t)(n); \
if (nn >= breakeven_point) memcpy((d), (s), nn); \
else if (nn > 0) { /* proc call overhead is worth only for large strings*/\
- register char *dd; register const char *ss; \
+ char *dd; const char *ss; \
for (ss=(s), dd=(d); nn>0; nn--) *dd++ = *ss++; } }
#define fast_memset(d,c,n) \
- { register size_t nn = (size_t)(n); \
+ { size_t nn = (size_t)(n); \
if (nn >= breakeven_point) memset((d), (int)(c), nn); \
else if (nn > 0) { /* proc call overhead is worth only for large strings*/\
- register char *dd; register const int cc=(int)(c); \
+ char *dd; const int cc=(int)(c); \
for (dd=(d); nn>0; nn--) *dd++ = cc; } }
/* prototypes */
#endif
#endif
+ /* FIXME: better place */
+#include "xbt/sysdep.h"
+
/* declarations */
static char credits[] = "\n\
#endif
- /* FIXME: better place */
-#include "xbt/sysdep.h"
-
char *bvprintf(const char *fmt, va_list ap)
{
char *res;