diff -r 238c37e4c395 Modules/posixmodule.c --- a/Modules/posixmodule.c Sat Aug 03 11:39:39 2013 +0200 +++ b/Modules/posixmodule.c Fri Aug 09 00:46:14 2013 -0400 @@ -10143,6 +10143,14 @@ goto exit; } + /* + * On Linux using ZFS (native), if attr is >128 bytes, + * and we ask for 128 bytes, we successfully get 128 bytes + * and no error is indicated. So we have to retry. + */ + if ((result == buffer_size) && (buffer_size != XATTR_SIZE_MAX)) + continue; + if (result != buffer_size) { /* Can only shrink. */ _PyBytes_Resize(&buffer, result);