Deal with recursive symlinks in directory traversal in buck.py.
Deal with recursive symlinks in directory traversal in buck.py.

Summary:
Recently this file was changed to do a recursive traversal while following
symlinks, without dealing with recursive symlinks.

This diff deals with recursive symlinks by recording all visited paths, and
skipping the ones that have already been visited.

dpursehouse/buck,mread/buck,justinmuller/buck,illicitonion/buck,pwz3n0/buck,Learn-Android-app/buck,justinmuller/buck,liuyang-li/buck,stuhood/buck,Learn-Android-app/buck,saleeh93/buck-cutom,kageiit/buck,JoelMarcey/buck,siddhartharay007/buck,shs96c/buck,Learn-Android-app/buck,sdwilsh/buck,OkBuilds/buck,shybovycha/buck,rmaz/buck,daedric/buck,mread/buck,dushmis/buck,Dominator008/buck,clonetwin26/buck,raviagarwal7/buck,ilya-klyuchnikov/buck,dpursehouse/buck,sdwilsh/buck,shs96c/buck,LegNeato/buck,hgl888/buck,raviagarwal7/buck,mikekap/buck,dushmis/buck,stuhood/buck,daedric/buck,siddhartharay007/buck,janicduplessis/buck,daedric/buck,grumpyjames/buck,Addepar/buck,rowillia/buck,darkforestzero/buck,raviagarwal7/buck,lukw00/buck,zpao/buck,raviagarwal7/buck,mogers/buck,brettwooldridge/buck,ilya-klyuchnikov/buck,LegNeato/buck,Heart2009/buck,luiseduardohdbackup/buck,zhan-xiong/buck,brettwooldridge/buck,davido/buck,romanoid/buck,SeleniumHQ/buck,vschs007/buck,darkforestzero/buck,dsyang/buck,clonetwin26/buck,darkforestzero/buck,OkBuilds/buck,JoelMarcey/buck,OkBuilds/buck,dsyang/buck,siddhartharay007/buck,mogers/buck,dpursehouse/buck,Addepar/buck,marcinkwiatkowski/buck,davido/buck,tgummerer/buck,Dominator008/buck,kageiit/buck,zhan-xiong/buck,brettwooldridge/buck,zhuxiaohao/buck,mnuessler/buck,OkBuilds/buck,neonichu/buck,ilya-klyuchnikov/buck,zpao/buck,nguyentruongtho/buck,rmaz/buck,Dominator008/buck,rhencke/buck,shybovycha/buck,davido/buck,nguyentruongtho/buck,raviagarwal7/buck,bocon13/buck,siddhartharay007/buck,vine/buck,Heart2009/buck,saleeh93/buck-cutom,pwz3n0/buck,romanoid/buck,mnuessler/buck,vschs007/buck,mnuessler/buck,zpao/buck,clonetwin26/buck,shs96c/buck,rhencke/buck,rmaz/buck,dsyang/buck,Dominator008/buck,Addepar/buck,darkforestzero/buck,dsyang/buck,Distrotech/buck,saleeh93/buck-cutom,liuyang-li/buck,Dominator008/buck,ilya-klyuchnikov/buck,shybovycha/buck,vschs007/buck,dsyang/buck,davido/buck,SeleniumHQ/buck,stuhood/buck,luiseduardohdbackup/buck,stuhood/buck,mikekap/buck,mikekap/buck,grumpyjames/buck,hgl888/buck,Dominator008/buck,vine/buck,k21/buck,dpursehouse/buck,LegNeato/buck,robbertvanginkel/buck,1yvT0s/buck,mogers/buck,luiseduardohdbackup/buck,SeleniumHQ/buck,mikekap/buck,justinmuller/buck,justinmuller/buck,vine/buck,zhan-xiong/buck,MarkRunWu/buck,artiya4u/buck,Heart2009/buck,OkBuilds/buck,facebook/buck,mikekap/buck,artiya4u/buck,raviagarwal7/buck,rowillia/buck,facebook/buck,lukw00/buck,mogers/buck,tgummerer/buck,hgl888/buck,mogers/buck,pwz3n0/buck,OkBuilds/buck,illicitonion/buck,janicduplessis/buck,shs96c/buck,marcinkwiatkowski/buck,neonichu/buck,zpao/buck,artiya4u/buck,liuyang-li/buck,clonetwin26/buck,OkBuilds/buck,sdwilsh/buck,k21/buck,pwz3n0/buck,illicitonion/buck,ilya-klyuchnikov/buck,zhan-xiong/buck,stuhood/buck,shs96c/buck,k21/buck,k21/buck,vschs007/buck,clonetwin26/buck,bocon13/buck,brettwooldridge/buck,grumpyjames/buck,k21/buck,JoelMarcey/buck,Distrotech/buck,neonichu/buck,1yvT0s/buck,LegNeato/buck,SeleniumHQ/buck,liuyang-li/buck,darkforestzero/buck,rowillia/buck,neonichu/buck,vine/buck,mnuessler/buck,JoelMarcey/buck,dushmis/buck,bocon13/buck,davido/buck,1yvT0s/buck,sdwilsh/buck,shs96c/buck,SeleniumHQ/buck,luiseduardohdbackup/buck,mogers/buck,GerritCodeReview/buck,janicduplessis/buck,lukw00/buck,ilya-klyuchnikov/buck,robbertvanginkel/buck,rmaz/buck,clonetwin26/buck,shybovycha/buck,saleeh93/buck-cutom,facebook/buck,illicitonion/buck,k21/buck,shybovycha/buck,zhuxiaohao/buck,dsyang/buck,marcinkwiatkowski/buck,sdwilsh/buck,lukw00/buck,dpursehouse/buck,Heart2009/buck,robbertvanginkel/buck,luiseduardohdbackup/buck,Addepar/buck,LegNeato/buck,bocon13/buck,shybovycha/buck,mikekap/buck,mread/buck,Distrotech/buck,LegNeato/buck,Learn-Android-app/buck,MarkRunWu/buck,LegNeato/buck,raviagarwal7/buck,pwz3n0/buck,janicduplessis/buck,JoelMarcey/buck,Learn-Android-app/buck,rowillia/buck,SeleniumHQ/buck,saleeh93/buck-cutom,daedric/buck,zhan-xiong/buck,lukw00/buck,mikekap/buck,davido/buck,k21/buck,Distrotech/buck,Learn-Android-app/buck,JoelMarcey/buck,clonetwin26/buck,thinkernel/buck,rmaz/buck,liuyang-li/buck,mnuessler/buck,daedric/buck,neonichu/buck,k21/buck,Distrotech/buck,hgl888/buck,davido/buck,rmaz/buck,liuyang-li/buck,GerritCodeReview/buck,raviagarwal7/buck,belomx/open_tools,vine/buck,bocon13/buck,zhan-xiong/buck,romanoid/buck,nguyentruongtho/buck,brettwooldridge/buck,siddhartharay007/buck,LegNeato/buck,romanoid/buck,thinkernel/buck,bocon13/buck,belomx/open_tools,1yvT0s/buck,shs96c/buck,daedric/buck,dsyang/buck,SeleniumHQ/buck,illicitonion/buck,romanoid/buck,justinmuller/buck,Dominator008/buck,zhan-xiong/buck,lukw00/buck,k21/buck,davido/buck,raviagarwal7/buck,nguyentruongtho/buck,zhan-xiong/buck,brettwooldridge/buck,janicduplessis/buck,stuhood/buck,lukw00/buck,illicitonion/buck,hgl888/buck,Dominator008/buck,rhencke/buck,robbertvanginkel/buck,rowillia/buck,1yvT0s/buck,JoelMarcey/buck,rmaz/buck,facebook/buck,dushmis/buck,darkforestzero/buck,grumpyjames/buck,zhan-xiong/buck,vschs007/buck,stuhood/buck,ilya-klyuchnikov/buck,Addepar/buck,marcinkwiatkowski/buck,stuhood/buck,vschs007/buck,daedric/buck,vine/buck,siddhartharay007/buck,rhencke/buck,vine/buck,Distrotech/buck,rmaz/buck,facebook/buck,nguyentruongtho/buck,shs96c/buck,stuhood/buck,daedric/buck,shybovycha/buck,1yvT0s/buck,k21/buck,darkforestzero/buck,davido/buck,MarkRunWu/buck,rmaz/buck,thinkernel/buck,LegNeato/buck,vine/buck,pwz3n0/buck,illicitonion/buck,zhuxiaohao/buck,raviagarwal7/buck,shybovycha/buck,rmaz/buck,vschs007/buck,davido/buck,robbertvanginkel/buck,marcinkwiatkowski/buck,grumpyjames/buck,mnuessler/buck,justinmuller/buck,rhencke/buck,neonichu/buck,janicduplessis/buck,shybovycha/buck,neonichu/buck,darkforestzero/buck,kageiit/buck,marcinkwiatkowski/buck,zhan-xiong/buck,janicduplessis/buck,siddhartharay007/buck,robbertvanginkel/buck,mread/buck,marcinkwiatkowski/buck,jackminicloud/buck,artiya4u/buck,clonetwin26/buck,nguyentruongtho/buck,bocon13/buck,marcinkwiatkowski/buck,brettwooldridge/buck,shs96c/buck,daedric/buck,MarkRunWu/buck,zhuxiaohao/buck,romanoid/buck,tgummerer/buck,robbertvanginkel/buck,nguyentruongtho/buck,pwz3n0/buck,vschs007/buck,facebook/buck,mikekap/buck,rhencke/buck,justinmuller/buck,daedric/buck,zpao/buck,Learn-Android-app/buck,mogers/buck,luiseduardohdbackup/buck,davido/buck,JoelMarcey/buck,tgummerer/buck,Heart2009/buck,Addepar/buck,OkBuilds/buck,stuhood/buck,illicitonion/buck,hgl888/buck,rhencke/buck,brettwooldridge/buck,mogers/buck,vschs007/buck,tgummerer/buck,romanoid/buck,raviagarwal7/buck,zhuxiaohao/buck,luiseduardohdbackup/buck,justinmuller/buck,bocon13/buck,dsyang/buck,raviagarwal7/buck,ilya-klyuchnikov/buck,Heart2009/buck,artiya4u/buck,vschs007/buck,mikekap/buck,OkBuilds/buck,robbertvanginkel/buck,vine/buck,zpao/buck,daedric/buck,zhan-xiong/buck,Dominator008/buck,Heart2009/buck,artiya4u/buck,1yvT0s/buck,rowillia/buck,vschs007/buck,clonetwin26/buck,mogers/buck,mikekap/buck,dsyang/buck,mogers/buck,tgummerer/buck,rmaz/buck,artiya4u/buck,illicitonion/buck,dsyang/buck,rowillia/buck,liuyang-li/buck,dushmis/buck,clonetwin26/buck,Addepar/buck,tgummerer/buck,grumpyjames/buck,MarkRunWu/buck,sdwilsh/buck,kageiit/buck,Addepar/buck,LegNeato/buck,zhuxiaohao/buck,facebook/buck,marcinkwiatkowski/buck,neonichu/buck,k21/buck,liuyang-li/buck,romanoid/buck,JoelMarcey/buck,Addepar/buck,Addepar/buck,lukw00/buck,shybovycha/buck,janicduplessis/buck,SeleniumHQ/buck,romanoid/buck,shybovycha/buck,siddhartharay007/buck,lukw00/buck,brettwooldridge/buck,brettwooldridge/buck,mread/buck,dsyang/buck,shs96c/buck,Addepar/buck,OkBuilds/buck,artiya4u/buck,darkforestzero/buck,Distrotech/buck,stuhood/buck,romanoid/buck,k21/buck,vine/buck,robbertvanginkel/buck,marcinkwiatkowski/buck,hgl888/buck,janicduplessis/buck,Dominator008/buck,grumpyjames/buck,justinmuller/buck,Distrotech/buck,sdwilsh/buck,mogers/buck,marcinkwiatkowski/buck,Learn-Android-app/buck,dpursehouse/buck,rmaz/buck,sdwilsh/buck,romanoid/buck,lukw00/buck,tgummerer/buck,illicitonion/buck,janicduplessis/buck,kageiit/buck,JoelMarcey/buck,brettwooldridge/buck,shs96c/buck,Addepar/buck,Distrotech/buck,pwz3n0/buck,clonetwin26/buck,dsyang/buck,ilya-klyuchnikov/buck,JoelMarcey/buck,1yvT0s/buck,illicitonion/buck,shybovycha/buck,pwz3n0/buck,SeleniumHQ/buck,marcinkwiatkowski/buck,vschs007/buck,artiya4u/buck,dushmis/buck,MarkRunWu/buck,grumpyjames/buck,siddhartharay007/buck,bocon13/buck,zhuxiaohao/buck,davido/buck,dushmis/buck,kageiit/buck,Dominator008/buck,lukw00/buck,hgl888/buck,marcinkwiatkowski/buck,luiseduardohdbackup/buck,sdwilsh/buck,brettwooldridge/buck,tgummerer/buck,OkBuilds/buck,vschs007/buck,illicitonion/buck,rmaz/buck,belomx/open_tools,rowillia/buck,dushmis/buck,OkBuilds/buck,LegNeato/buck,Learn-Android-app/buck,shs96c/buck,liuyang-li/buck,jackminicloud/buck,kageiit/buck,SeleniumHQ/buck,raviagarwal7/buck,ilya-klyuchnikov/buck,SeleniumHQ/buck,darkforestzero/buck,janicduplessis/buck,artiya4u/buck,darkforestzero/buck,davido/buck,bocon13/buck,mnuessler/buck,clonetwin26/buck,daedric/buck,justinmuller/buck,sdwilsh/buck,dsyang/buck,zhuxiaohao/buck,bocon13/buck,grumpyjames/buck,justinmuller/buck,Heart2009/buck,jackminicloud/buck,GerritCodeReview/buck,mnuessler/buck,janicduplessis/buck,Addepar/buck,mnuessler/buck,rowillia/buck,rhencke/buck,illicitonion/buck,sdwilsh/buck,thinkernel/buck,grumpyjames/buck,grumpyjames/buck,mikekap/buck,dpursehouse/buck,liuyang-li/buck,luiseduardohdbackup/buck,darkforestzero/buck,pwz3n0/buck,zhan-xiong/buck,romanoid/buck,sdwilsh/buck,GerritCodeReview/buck,Dominator008/buck,Distrotech/buck,SeleniumHQ/buck,LegNeato/buck,liuyang-li/buck,hgl888/buck,rhencke/buck,saleeh93/buck-cutom,mread/buck,ilya-klyuchnikov/buck,Heart2009/buck,Distrotech/buck,artiya4u/buck,bocon13/buck,belomx/open_tools,robbertvanginkel/buck,pwz3n0/buck,clonetwin26/buck,rowillia/buck,MarkRunWu/buck,ilya-klyuchnikov/buck,rowillia/buck,robbertvanginkel/buck,SeleniumHQ/buck,MarkRunWu/buck,mikekap/buck,dpursehouse/buck,jackminicloud/buck,rhencke/buck,shs96c/buck,grumpyjames/buck,tgummerer/buck,Learn-Android-app/buck,neonichu/buck,vine/buck,rowillia/buck,justinmuller/buck,darkforestzero/buck,zpao/buck,dushmis/buck,Learn-Android-app/buck,robbertvanginkel/buck,OkBuilds/buck,JoelMarcey/buck,tgummerer/buck,robbertvanginkel/buck,daedric/buck,1yvT0s/buck,dushmis/buck,brettwooldridge/buck,k21/buck,LegNeato/buck,ilya-klyuchnikov/buck,rhencke/buck,zhuxiaohao/buck,zhan-xiong/buck,shybovycha/buck,romanoid/buck,justinmuller/buck,JoelMarcey/buck,sdwilsh/buck