if (!fname || !*fname) return 0;
- fd = open(fname,O_RDONLY);
+ fd = open(fname,O_RDONLY | O_TEXT);
if (fd == -1) return 0;
if (do_stat(fname, &st) == -1) {
if (!filename) return NULL;
- if ( (fd=open(filename,O_RDONLY)) == -1) {
+ if ( (fd=open(filename,O_RDONLY | O_TEXT)) == -1) {
rsyserr(FERROR, errno, "could not open password file \"%s\"",filename);
if (envpw) rprintf(FERROR,"falling back to RSYNC_PASSWORD environment variable.\n");
return NULL;