OK, I was able to verify it now, made a mistake earlier. I'll let somebody else decide if this is desired behaviour.
Steps to reproduce: $ echo "test" |xz > /tmp/test.txt.xz $ chmod 444 /tmp/test.txt.xz $ unxz /tmp/test.txt.xz $ ls -la /tmp/test.txt* -r--r--r-- 1 rolf rolf 5 Jun 4 13:06 /tmp/test.txt
gunzip exhibits the same behaviour, by the way.
OK, I was able to verify it now, made a mistake earlier. I'll let somebody else decide if this is desired behaviour.
Steps to reproduce:
$ echo "test" |xz > /tmp/test.txt.xz
$ chmod 444 /tmp/test.txt.xz
$ unxz /tmp/test.txt.xz
$ ls -la /tmp/test.txt*
-r--r--r-- 1 rolf rolf 5 Jun 4 13:06 /tmp/test.txt
gunzip exhibits the same behaviour, by the way.