A
lgorithmique
N
umérique
D
istribuée
Public GIT Repository
projects
/
simgrid.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Add a pimple^W^W an helper function
[simgrid.git]
/
src
/
xbt
/
snprintf.c
diff --git
a/src/xbt/snprintf.c
b/src/xbt/snprintf.c
index
b6f7b75
..
644c638
100644
(file)
--- a/
src/xbt/snprintf.c
+++ b/
src/xbt/snprintf.c
@@
-1026,3
+1026,17
@@
int portable_vsnprintf(char *str, size_t str_m, const char *fmt, va_list ap) {
return (int) str_l;
}
#endif
+
+
+/* FIXME: better place */
+#include "xbt/sysdep.h"
+
+char *bprintf(const char*fmt, ...) {
+ va_list ap;
+ char *res;
+
+ va_start(ap, fmt);
+ vasprintf(&res,fmt,ap);
+ va_end(ap);
+ return res;
+}