mailfs: try tlsclient program before stunnel

R=rsc
http://codereview.appspot.com/1169043
This commit is contained in:
Russ Cox 2010-05-11 08:25:08 -07:00
parent e18f0a49f3
commit 18ee9a80f1

View file

@ -755,7 +755,8 @@ imapdial(char *server, int mode)
fd[1] = dup(p[0], -1);
fd[2] = dup(2, -1);
tmp = esmprint("%s:993", server);
if(threadspawnl(fd, "/usr/sbin/stunnel", "stunnel", "-c", "-r", tmp, nil) < 0
if(threadspawnl(fd, "tlsclient", "tlsclient", tmp, nil) < 0
&& threadspawnl(fd, "/usr/sbin/stunnel", "stunnel", "-c", "-r", tmp, nil) < 0
&& threadspawnl(fd, "/usr/bin/stunnel", "stunnel", "-c", "-r", tmp, nil) < 0){
free(tmp);
close(p[0]);