Trying to replicate hash-object I found that is not working when using non-ascii characters.
$ printf hola | git hash-object -w --stdin
b8b4a4e2a5db3ebed5f5e02beb3e2d27bca9fc9a
$ printf "blob 4\0hola" | shasum
b8b4a4e2a5db3ebed5f5e02beb3e2d27bca9fc9a
But if I add the Pound symbol
$ printf hola£ | git hash-object -w --stdin
8f9852933655612593d0bbd43c9f7c6f25d947a0
$ printf "blob 5\0hola£" | shasum
54386ef126fcfc9e8242c6d6bade401b1f27999a
Any idea why is this happening?