Fix chmod

See  #46