The xdelta manual page needs documentation about the completely non-standard exit codes it uses when creating a delta, vis: 0 = Delta created, no difference 1 = Delta created, differences found else error. I had to check the source and found a line like: return control_offset != header_offset; What's more, this doesn't seem to correctly detect identical files either, I couldn't get it to return zero.
this its a workaround fix in main upstream, please import: https://github.com/jmacd/xdelta/commit/f60f342df2fa3379b572e3854d8439a2fa0b5375 solves the 1 or 0 exit status