Hello Pirmin,
>> If I do want to right align the numbers (%-5d) the function crashes my
>> program.
>
> This should not happen. Thank you for reporting. I just opened an issue
> about it:
>
> https://github.com/genodelabs/genode/issues/1485
unfortunately, I am not able to reproduce the problem. When modifying
the printf test using the attached patch, the program runs just fine.
Could you share a small test program that triggers the problem? That
would be greatly appreciated.
Best regards
Norman
--
Dr.-Ing. Norman Feske
Genode Labs
http://www.genode-labs.com · http://genode.org
Genode Labs GmbH · Amtsgericht Dresden · HRB 28424 · Sitz Dresden
Geschäftsführer: Dr.-Ing. Norman Feske, Christian Helmuth
diff --git a/repos/base/src/test/printf/main.cc b/repos/base/src/test/printf/main.cc
index 77d9118..bdd02d7 100644
--- a/repos/base/src/test/printf/main.cc
+++ b/repos/base/src/test/printf/main.cc
@@ -13,9 +13,13 @@
*/
#include <base/printf.h>
+#include <base/snprintf.h>
int main(int argc, char **argv)
{
+ char buf[10];
+ Genode::snprintf(buf, sizeof(buf), "%-5d", 1);
+
Genode::printf("-1 = %d = %ld\n", -1, -1L);
return 0;
------------------------------------------------------------------------------
BPM Camp - Free Virtual Workshop May 6th at 10am PDT/1PM EDT
Develop your own process in accordance with the BPMN 2 standard
Learn Process modeling best practices with Bonita BPM through live exercises
http://www.bonitasoft.com/be-part-of-it/events/bpm-camp-virtual- event?utm_
source=Sourceforge_BPM_Camp_5_6_15&utm_medium=email&utm_campaign=VA_SF
_______________________________________________
genode-main mailing list
genode-main@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/genode-main