This is relative to master. This seems to be required by the base
standard, not an XSI extension.
>From 4bdc2f611795e683405b55ac574247262a485f9f Mon Sep 17 00:00:00 2001
From: Greg Reagle <greg.rea...@umbc.edu>
Date: Fri, 2 Oct 2015 09:38:39 -0400
Subject: [PATCH] od: type 'c': format characters in octal as specified by
standard
---
od.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/od.c b/od.c
index 9521605..e39461d 100644
--- a/od.c
+++ b/od.c
@@ -59,7 +59,7 @@ printchar(FILE *f, unsigned char c)
if (strchr("\a\b\t\n\b\f\r\0", c)) {
fprintf(f, "%3s ", escdict[c]);
} else {
- fprintf(f, "%3c ", c);
+ fprintf(f, "%03hho ", c);
}
break;
default:
--
1.9.1