uutils/coreutils

Difference in offsets for `od --strings -N`

Open

#11613 opened on Apr 3, 2026

View on GitHub
 (3 comments) (0 reactions) (0 assignees)Rust (23,246 stars) (1,852 forks)batch import
U - odgood first issuereported-canonical-2

Description

This is a difference between uu od and GNU od, but uu's output is more reasonable. Should this be submitted to GNU coreutils' issue tracker?

root@b082d601e194:/tmp# od --version
od (GNU coreutils) 9.7
Packaged by Debian (9.7-3)
Copyright (C) 2025 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <https://gnu.org/licenses/gpl.html>.
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

Written by Jim Meyering.
root@b082d601e194:/tmp# printf "foo\0bar " | od --strings -N7
0000000 foo
root@b082d601e194:/tmp# printf "foo\0bar " | od --strings -N8
0000000 foo
0000003 bar
root@03081849be59:/tmp# od --version
od (uutils coreutils) 0.6.0
root@03081849be59:/tmp# printf "foo\0bar " | od --strings -N7
0000000 foo
0000004 bar
root@03081849be59:/tmp# printf "foo\0bar " | od --strings -N8
0000000 foo
0000004 bar

Contributor guide