allow writing attributes with write-only perms
allow writing attributes with write-only perms

* replace "r+" with "w" in fopen() flags to avoid EACCES when
opening attribute files with no read permission.

gburca/libiio,gburca/libiio,analogdevicesinc/libiio,analogdevicesinc/libiio,Sunderfield/libiio,Sunderfield/libiio,Sunderfield/libiio,gburca/libiio,analogdevicesinc/libiio,analogdevicesinc/libiio,sensarliar/libiio,sensarliar/libiio,sensarliar/libiio