diff options
author | Robert Göffringmann | 2008-03-10 20:34:34 +0000 |
---|---|---|
committer | Robert Göffringmann | 2008-03-10 20:34:34 +0000 |
commit | 4f30f09456cd672797e69d574888a65dd60dedce (patch) | |
tree | e85213daad9d52f66e6a30e15601194d8462f48f /backends/platform/ps2/ps2debug.cpp | |
parent | b1f1447234a5daf45f51336e7082af4c0bd151a1 (diff) | |
download | scummvm-rg350-4f30f09456cd672797e69d574888a65dd60dedce.tar.gz scummvm-rg350-4f30f09456cd672797e69d574888a65dd60dedce.tar.bz2 scummvm-rg350-4f30f09456cd672797e69d574888a65dd60dedce.zip |
forgot to commit these
svn-id: r31099
Diffstat (limited to 'backends/platform/ps2/ps2debug.cpp')
-rw-r--r-- | backends/platform/ps2/ps2debug.cpp | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/backends/platform/ps2/ps2debug.cpp b/backends/platform/ps2/ps2debug.cpp new file mode 100644 index 0000000000..272d256232 --- /dev/null +++ b/backends/platform/ps2/ps2debug.cpp @@ -0,0 +1,25 @@ +#include "ps2debug.h" +#include <stdio.h> +#include <stdlib.h> +#include <sio.h> + +void sioprintf(const char *zFormat, ...) { + va_list ap; + char resStr[2048]; + + va_start(ap,zFormat); + vsnprintf(resStr, 2048, zFormat, ap); + va_end(ap); + + char *pos = resStr; + while (*pos) { + if (*pos == '\n') { + // SIO terminal needs explicit CRLF + sio_putc('\r'); + sio_putc('\n'); + } else + sio_putc(*pos); + pos++; + } +} + |