Skip to content

Commit

Permalink
netrc: Read in text mode when cygwin
Browse files Browse the repository at this point in the history
Use text mode when cygwin to eliminate trailing carriage returns.

Bug: #258
  • Loading branch information
orgads authored and jay committed May 6, 2015
1 parent 9fcc297 commit 33058a1
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lib/netrc.c
Expand Up @@ -109,7 +109,11 @@ int Curl_parsenetrc(const char *host,
netrc_alloc = TRUE;
}

#ifdef __CYGWIN__
file = fopen(netrcfile, "rt");
#else
file = fopen(netrcfile, "r");
#endif
if(netrc_alloc)
free(netrcfile);
if(file) {
Expand Down

0 comments on commit 33058a1

Please sign in to comment.