Fix symlinked file handling.
Fix symlinked file handling.

Do not path join "rest" to the destination file when rest == '', which happens
when a file inside a symlinked directory is added. Otherwise an '/' is added
when it shouldn't.

TBR=cmp@chromium.org
NOTRY=true
BUG=
TEST=


Review URL: https://chromiumcodereview.appspot.com/10701102

git-svn-id: de016e52bd170d2d4f2344f9bf92d50478b649e0@145531 0039d316-1c4b-4281-b951-d872f2087c98

Fireblend/chromium-crosswalk,zcbenz/cefode-chromium,markYoungH/chromium.src,Just-D/chromium-1,anirudhSK/chromium,timopulkkinen/BubbleFish,PeterWangIntel/chromium-crosswalk,axinging/chromium-crosswalk,patrickm/chromium.src,markYoungH/chromium.src,timopulkkinen/BubbleFish,krieger-od/nwjs_chromium.src,hgl888/chromium-crosswalk,jaruba/chromium.src,TheTypoMaster/chromium-crosswalk,Just-D/chromium-1,Just-D/chromium-1,littlstar/chromium.src,axinging/chromium-crosswalk,TheTypoMaster/chromium-crosswalk,keishi/chromium,Just-D/chromium-1,ltilve/chromium,pozdnyakov/chromium-crosswalk,dushu1203/chromium.src,pozdnyakov/chromium-crosswalk,TheTypoMaster/chromium-crosswalk,Just-D/chromium-1,krieger-od/nwjs_chromium.src,axinging/chromium-crosswalk,littlstar/chromium.src,dushu1203/chromium.src,nacl-webkit/chrome_deps,keishi/chromium,ChromiumWebApps/chromium,hujiajie/pa-chromium,chuan9/chromium-crosswalk,mogoweb/chromium-crosswalk,Pluto-tv/chromium-crosswalk,dushu1203/chromium.src,littlstar/chromium.src,krieger-od/nwjs_chromium.src,Jonekee/chromium.src,dednal/chromium.src,pozdnyakov/chromium-crosswalk,Pluto-tv/chromium-crosswalk,ChromiumWebApps/chromium,bright-sparks/chromium-spacewalk,ChromiumWebApps/chromium,dednal/chromium.src,ltilve/chromium,anirudhSK/chromium,anirudhSK/chromium,zcbenz/cefode-chromium,ChromiumWebApps/chromium,mogoweb/chromium-crosswalk,fujunwei/chromium-crosswalk,Chilledheart/chromium,Pluto-tv/chromium-crosswalk,timopulkkinen/BubbleFish,ChromiumWebApps/chromium,anirudhSK/chromium,nacl-webkit/chrome_deps,jaruba/chromium.src,bright-sparks/chromium-spacewalk,fujunwei/chromium-crosswalk,zcbenz/cefode-chromium,hujiajie/pa-chromium,chuan9/chromium-crosswalk,anirudhSK/chromium,littlstar/chromium.src,anirudhSK/chromium,M4sse/chromium.src,pozdnyakov/chromium-crosswalk,Jonekee/chromium.src,mogoweb/chromium-crosswalk,zcbenz/cefode-chromium,crosswalk-project/chromium-crosswalk-efl,dednal/chromium.src,Just-D/chromium-1,jaruba/chromium.src,nacl-webkit/chrome_deps,M4sse/chromium.src,jaruba/chromium.src,bright-sparks/chromium-spacewalk,hgl888/chromium-crosswalk-efl,junmin-zhu/chromium-rivertrail,hgl888/chromium-crosswalk-efl,TheTypoMaster/chromium-crosswalk,hujiajie/pa-chromium,timopulkkinen/BubbleFish,mogoweb/chromium-crosswalk,patrickm/chromium.src,markYoungH/chromium.src,junmin-zhu/chromium-rivertrail,anirudhSK/chromium,ondra-novak/chromium.src,TheTypoMaster/chromium-crosswalk,M4sse/chromium.src,fujunwei/chromium-crosswalk,ondra-novak/chromium.src,nacl-webkit/chrome_deps,junmin-zhu/chromium-rivertrail,TheTypoMaster/chromium-crosswalk,pozdnyakov/chromium-crosswalk,Chilledheart/chromium,Fireblend/chromium-crosswalk,dednal/chromium.src,hgl888/chromium-crosswalk,jaruba/chromium.src,keishi/chromium,nacl-webkit/chrome_deps,Fireblend/chromium-crosswalk,dushu1203/chromium.src,ltilve/chromium,TheTypoMaster/chromium-crosswalk,hgl888/chromium-crosswalk-efl,dednal/chromium.src,littlstar/chromium.src,ChromiumWebApps/chromium,PeterWangIntel/chromium-crosswalk,ondra-novak/chromium.src,anirudhSK/chromium,littlstar/chromium.src,nacl-webkit/chrome_deps,Pluto-tv/chromium-crosswalk,ChromiumWebApps/chromium,junmin-zhu/chromium-rivertrail,PeterWangIntel/chromium-crosswalk,dushu1203/chromium.src,krieger-od/nwjs_chromium.src,hujiajie/pa-chromium,mohamed--abdel-maksoud/chromium.src,keishi/chromium,bright-sparks/chromium-spacewalk,chuan9/chromium-crosswalk,junmin-zhu/chromium-rivertrail,ltilve/chromium,patrickm/chromium.src,ChromiumWebApps/chromium,ondra-novak/chromium.src,keishi/chromium,hgl888/chromium-crosswalk,patrickm/chromium.src,fujunwei/chromium-crosswalk,zcbenz/cefode-chromium,M4sse/chromium.src,timopulkkinen/BubbleFish,nacl-webkit/chrome_deps,zcbenz/cefode-chromium,Fireblend/chromium-crosswalk,patrickm/chromium.src,Jonekee/chromium.src,bright-sparks/chromium-spacewalk,chuan9/chromium-crosswalk,ondra-novak/chromium.src,Chilledheart/chromium,TheTypoMaster/chromium-crosswalk,PeterWangIntel/chromium-crosswalk,anirudhSK/chromium,dushu1203/chromium.src,ltilve/chromium,zcbenz/cefode-chromium,patrickm/chromium.src,Fireblend/chromium-crosswalk,pozdnyakov/chromium-crosswalk,krieger-od/nwjs_chromium.src,M4sse/chromium.src,keishi/chromium,Fireblend/chromium-crosswalk,ondra-novak/chromium.src,Chilledheart/chromium,Chilledheart/chromium,mogoweb/chromium-crosswalk,TheTypoMaster/chromium-crosswalk,axinging/chromium-crosswalk,dushu1203/chromium.src,mohamed--abdel-maksoud/chromium.src,jaruba/chromium.src,hgl888/chromium-crosswalk-efl,bright-sparks/chromium-spacewalk,crosswalk-project/chromium-crosswalk-efl,crosswalk-project/chromium-crosswalk-efl,dednal/chromium.src,hujiajie/pa-chromium,Jonekee/chromium.src,mogoweb/chromium-crosswalk,fujunwei/chromium-crosswalk,hujiajie/pa-chromium,timopulkkinen/BubbleFish,hgl888/chromium-crosswalk,krieger-od/nwjs_chromium.src,ChromiumWebApps/chromium,chuan9/chromium-crosswalk,chuan9/chromium-crosswalk,hgl888/chromium-crosswalk,jaruba/chromium.src,fujunwei/chromium-crosswalk,mohamed--abdel-maksoud/chromium.src,chuan9/chromium-crosswalk,hgl888/chromium-crosswalk-efl,pozdnyakov/chromium-crosswalk,jaruba/chromium.src,crosswalk-project/chromium-crosswalk-efl,patrickm/chromium.src,littlstar/chromium.src,markYoungH/chromium.src,markYoungH/chromium.src,fujunwei/chromium-crosswalk,hgl888/chromium-crosswalk-efl,timopulkkinen/BubbleFish,markYoungH/chromium.src,mogoweb/chromium-crosswalk,Jonekee/chromium.src,ChromiumWebApps/chromium,dednal/chromium.src,Chilledheart/chromium,ondra-novak/chromium.src,keishi/chromium,markYoungH/chromium.src,junmin-zhu/chromium-rivertrail,Pluto-tv/chromium-crosswalk,mogoweb/chromium-crosswalk,zcbenz/cefode-chromium,mohamed--abdel-maksoud/chromium.src,Just-D/chromium-1,hujiajie/pa-chromium,dushu1203/chromium.src,axinging/chromium-crosswalk,jaruba/chromium.src,hgl888/chromium-crosswalk,dednal/chromium.src,junmin-zhu/chromium-rivertrail,anirudhSK/chromium,ltilve/chromium,crosswalk-project/chromium-crosswalk-efl,M4sse/chromium.src,keishi/chromium,timopulkkinen/BubbleFish,patrickm/chromium.src,mohamed--abdel-maksoud/chromium.src,hgl888/chromium-crosswalk-efl,Fireblend/chromium-crosswalk,mohamed--abdel-maksoud/chromium.src,jaruba/chromium.src,Pluto-tv/chromium-crosswalk,nacl-webkit/chrome_deps,M4sse/chromium.src,hgl888/chromium-crosswalk,axinging/chromium-crosswalk,Jonekee/chromium.src,krieger-od/nwjs_chromium.src,krieger-od/nwjs_chromium.src,mohamed--abdel-maksoud/chromium.src,hujiajie/pa-chromium,markYoungH/chromium.src,crosswalk-project/chromium-crosswalk-efl,keishi/chromium,axinging/chromium-crosswalk,anirudhSK/chromium,hujiajie/pa-chromium,ltilve/chromium,Jonekee/chromium.src,zcbenz/cefode-chromium,markYoungH/chromium.src,mohamed--abdel-maksoud/chromium.src,PeterWangIntel/chromium-crosswalk,crosswalk-project/chromium-crosswalk-efl,dushu1203/chromium.src,dednal/chromium.src,krieger-od/nwjs_chromium.src,pozdnyakov/chromium-crosswalk,junmin-zhu/chromium-rivertrail,mohamed--abdel-maksoud/chromium.src,Chilledheart/chromium,keishi/chromium,mogoweb/chromium-crosswalk,anirudhSK/chromium,mohamed--abdel-maksoud/chromium.src,fujunwei/chromium-crosswalk,axinging/chromium-crosswalk,chuan9/chromium-crosswalk,keishi/chromium,PeterWangIntel/chromium-crosswalk,patrickm/chromium.src,ondra-novak/chromium.src,Chilledheart/chromium,PeterWangIntel/chromium-crosswalk,Just-D/chromium-1,axinging/chromium-crosswalk,nacl-webkit/chrome_deps,bright-sparks/chromium-spacewalk,PeterWangIntel/chromium-crosswalk,M4sse/chromium.src,Just-D/chromium-1,ltilve/chromium,Pluto-tv/chromium-crosswalk,timopulkkinen/BubbleFish,crosswalk-project/chromium-crosswalk-efl,Jonekee/chromium.src,zcbenz/cefode-chromium,Fireblend/chromium-crosswalk,Pluto-tv/chromium-crosswalk,junmin-zhu/chromium-rivertrail,Fireblend/chromium-crosswalk,ondra-novak/chromium.src,dushu1203/chromium.src,littlstar/chromium.src,mohamed--abdel-maksoud/chromium.src,hgl888/chromium-crosswalk-efl,pozdnyakov/chromium-crosswalk,hgl888/chromium-crosswalk,M4sse/chromium.src,timopulkkinen/BubbleFish,jaruba/chromium.src,hgl888/chromium-crosswalk-efl,bright-sparks/chromium-spacewalk,krieger-od/nwjs_chromium.src,bright-sparks/chromium-spacewalk,Jonekee/chromium.src,mogoweb/chromium-crosswalk,nacl-webkit/chrome_deps,pozdnyakov/chromium-crosswalk,pozdnyakov/chromium-crosswalk,axinging/chromium-crosswalk,Jonekee/chromium.src,nacl-webkit/chrome_deps,ltilve/chromium,axinging/chromium-crosswalk,Jonekee/chromium.src,Pluto-tv/chromium-crosswalk,junmin-zhu/chromium-rivertrail,hgl888/chromium-crosswalk-efl,PeterWangIntel/chromium-crosswalk,dednal/chromium.src,hujiajie/pa-chromium,Chilledheart/chromium,dushu1203/chromium.src,chuan9/chromium-crosswalk,zcbenz/cefode-chromium,timopulkkinen/BubbleFish,M4sse/chromium.src,hgl888/chromium-crosswalk,M4sse/chromium.src,krieger-od/nwjs_chromium.src,crosswalk-project/chromium-crosswalk-efl,markYoungH/chromium.src,dednal/chromium.src,markYoungH/chromium.src,fujunwei/chromium-crosswalk,junmin-zhu/chromium-rivertrail,ChromiumWebApps/chromium,ChromiumWebApps/chromium,hujiajie/pa-chromium