auto merge of #1353 : dhedlund/servo/resource_port_and_user, r=pcwalton
auto merge of #1353 : dhedlund/servo/resource_port_and_user, r=pcwalton

User credentials and port were not being preserved when pre-fetching path-based resources.  For example, consider the following HTML:

```html
<html>
  <body>
    <img src="logo.png" />
  </body>
```

Running the following command would try to fetch the image from `http://localhost/my-site/logo.png` and crash the browser with ConnectionRefused error:
```
$ ./servo http://foo:bar@localhost:8080/my-site/
task '<unnamed>' failed at 'Unhandled condition: io_error: rt::io::IoError{kind: ConnectionRefused, desc: "connection refused", detail: None}', /home/daniel/Programming/servo/src/compiler/rust/src/libstd/condition.rs:131
...
```

This should now be fixed.

saratang/servo,splav/servo,pyfisch/servo,akosel/servo,mrobinson/servo,seanmonstar/servo,tschneidereit/servo,GyrosOfWar/servo,jimberlage/servo,bjwbell/servo,evilpie/servo,dmarcos/servo,zhangjunlei26/servo,wpgallih/servo,saratang/servo,seanmonstar/servo,emilio/servo,thiagopnts/servo,nerith/servo,steveklabnik/servo,dsandeephegde/servo,paulrouget/servo,mdibaiee/servo,froydnj/servo,youprofit/servo,KiChjang/servo,Shraddha512/servo,g-k/servo,echochamber/servo,anthgur/servo,fiji-flo/servo,j3parker/servo,ryancanhelpyou/servo,g-k/servo,wpgallih/servo,splav/servo,Shraddha512/servo,bjwbell/servo,saneyuki/servo,boghison/servo,anthgur/servo,nnethercote/servo,dagnir/servo,snf/servo,mbrubeck/servo,GyrosOfWar/servo,avadacatavra/servo,canaltinova/servo,walac/servo,aidanhs/servo,luniv/servo,eddyb/servo,dati91/servo,codemac/servo,upsuper/servo,peterjoel/servo,g-k/servo,peterjoel/servo,jdramani/servo,meh/servo,karlito40/servo,pgonda/servo,walac/servo,dhananjay92/servo,dvberkel/servo,brendandahl/servo,Adenilson/prototype-viewing-distance,splav/servo,tschneidereit/servo,dsandeephegde/servo,kindersung/servo,peterjoel/servo,nick-thompson/servo,nick-thompson/servo,bjwbell/servo,vks/servo,rentongzhang/servo,zhangjunlei26/servo,deokjinkim/servo,wpgallih/servo,canaltinova/servo,snf/servo,echochamber/servo,jdramani/servo,samfoo/servo,zentner-kyle/servo,WriterOfAlicrow/servo,Shraddha512/servo,wartman4404/servo,jgraham/servo,mattnenterprise/servo,hyowon/servo,nrc/servo,KiChjang/servo,canaltinova/servo,bfrohs/servo,indykish/servo,jdramani/servo,pgonda/servo,srbhklkrn/SERVOENGINE,CJ8664/servo,juzer10/servo,aidanhs/servo,deokjinkim/servo,dati91/servo,ConnorGBrewster/servo,szeged/servo,rixrix/servo,A-deLuna/servo,A-deLuna/servo,seanmonstar/servo,saneyuki/servo,nick-thompson/servo,Shraddha512/servo,sadmansk/servo,paulrouget/servo,AnthonyBroadCrawford/servo,nick-thompson/servo,karlito40/servo,dvberkel/servo,meh/servo,aidanhs/servo,aidanhs/servo,srbhklkrn/SERVOENGINE,mukilan/servo,zentner-kyle/servo,pgonda/servo,Adenilson/prototype-viewing-distance,ryancanhelpyou/servo,szeged/servo,nick-thompson/servo,boghison/servo,indykish/servo,ConnorGBrewster/servo,Adenilson/prototype-viewing-distance,mbrubeck/servo,KiChjang/servo,nerith/servo,karlito40/servo,AnthonyBroadCrawford/servo,tempbottle/servo,wartman4404/servo,caldwell/servo,tafia/servo,DominoTree/servo,froydnj/servo,KiChjang/servo,kindersung/servo,A-deLuna/servo,mdibaiee/servo,rnestler/servo,canaltinova/servo,Shraddha512/servo,tafia/servo,boghison/servo,deokjinkim/servo,rnestler/servo,DominoTree/servo,KiChjang/servo,juzer10/servo,eddyb/servo,dagnir/servo,saneyuki/servo,fiji-flo/servo,s142857/servo,shrenikgala/servo,caldwell/servo,zhangjunlei26/servo,huonw/servo,ConnorGBrewster/servo,eddyb/servo,s142857/servo,dhananjay92/servo,mrobinson/servo,mattnenterprise/servo,WriterOfAlicrow/servo,brendandahl/servo,meh/servo,paulrouget/servo,upsuper/servo,canaltinova/servo,ryancanhelpyou/servo,pyfisch/servo,walac/servo,pyfisch/servo,walac/servo,GreenRecycleBin/servo,dati91/servo,runarberg/servo,evilpie/servo,nrc/servo,caldwell/servo,mt2d2/servo,paulrouget/servo,indykish/servo,evilpie/servo,tafia/servo,mt2d2/servo,CJ8664/servo,nnethercote/servo,ryancanhelpyou/servo,youprofit/servo,mt2d2/servo,dagnir/servo,pgonda/servo,walac/servo,jimberlage/servo,rnestler/servo,echochamber/servo,CJ8664/servo,bjwbell/servo,deokjinkim/servo,cbrewster/servo,huonw/servo,CJ8664/servo,tafia/servo,saneyuki/servo,hyowon/servo,snf/servo,wpgallih/servo,saneyuki/servo,DominoTree/servo,evilpie/servo,huonw/servo,pyecs/servo,mrobinson/servo,nerith/servo,mt2d2/servo,huonw/servo,hyowon/servo,srbhklkrn/SERVOENGINE,seanmonstar/servo,meh/servo,AnthonyBroadCrawford/servo,nick-thompson/servo,karlito40/servo,mrobinson/servo,KiChjang/servo,evilpie/servo,s142857/servo,WriterOfAlicrow/servo,dhananjay92/servo,ruud-v-a/servo,canaltinova/servo,srbhklkrn/SERVOENGINE,pgonda/servo,splav/servo,ruud-v-a/servo,nrc/servo,runarberg/servo,pyfisch/servo,mbrubeck/servo,paulrouget/servo,sadmansk/servo,dvberkel/servo,mbrubeck/servo,splav/servo,A-deLuna/servo,CJ8664/servo,shrenikgala/servo,GyrosOfWar/servo,notriddle/servo,cbrewster/servo,michaelwu/servo,nrc/servo,karlito40/servo,avadacatavra/servo,Adenilson/prototype-viewing-distance,jimberlage/servo,pyfisch/servo,ryancanhelpyou/servo,tafia/servo,saratang/servo,runarberg/servo,metajack/servo,szeged/servo,dhananjay92/servo,ryancanhelpyou/servo,GreenRecycleBin/servo,sadmansk/servo,splav/servo,paulrouget/servo,caldwell/servo,youprofit/servo,dagnir/servo,jlegendary/servo,pyecs/servo,eddyb/servo,tschneidereit/servo,mbrubeck/servo,snf/servo,dvberkel/servo,avadacatavra/servo,nnethercote/servo,rnestler/servo,dmarcos/servo,evilpie/servo,paulrouget/servo,anthgur/servo,thiagopnts/servo,srbhklkrn/SERVOENGINE,nnethercote/servo,vks/servo,dsandeephegde/servo,boghison/servo,shrenikgala/servo,aidanhs/servo,echochamber/servo,rixrix/servo,Adenilson/prototype-viewing-distance,saneyuki/servo,emilio/servo,froydnj/servo,boghison/servo,SimonSapin/servo,eddyb/servo,indykish/servo,codemac/servo,larsbergstrom/servo,nnethercote/servo,dsandeephegde/servo,metajack/servo,bjwbell/servo,dsandeephegde/servo,larsbergstrom/servo,nnethercote/servo,s142857/servo,GreenRecycleBin/servo,tschneidereit/servo,akosel/servo,g-k/servo,aidanhs/servo,RenaudParis/servo,SimonSapin/servo,dmarcos/servo,vks/servo,codemac/servo,SimonSapin/servo,thiagopnts/servo,A-deLuna/servo,A-deLuna/servo,j3parker/servo,Shraddha512/servo,jimberlage/servo,shrenikgala/servo,pyecs/servo,kindersung/servo,snf/servo,deokjinkim/servo,dati91/servo,runarberg/servo,aweinstock314/servo,steveklabnik/servo,srbhklkrn/SERVOENGINE,AnthonyBroadCrawford/servo,s142857/servo,szeged/servo,szeged/servo,dmarcos/servo,rnestler/servo,echochamber/servo,notriddle/servo,vks/servo,fiji-flo/servo,peterjoel/servo,mattnenterprise/servo,zhangjunlei26/servo,tempbottle/servo,cbrewster/servo,jlegendary/servo,jlegendary/servo,pyecs/servo,RenaudParis/servo,GreenRecycleBin/servo,rixrix/servo,nrc/servo,wartman4404/servo,emilio/servo,Adenilson/prototype-viewing-distance,RenaudParis/servo,dmarcos/servo,brendandahl/servo,szeged/servo,paulrouget/servo,evilpie/servo,seanmonstar/servo,tempbottle/servo,chotchki/servo,upsuper/servo,rentongzhang/servo,splav/servo,ConnorGBrewster/servo,avadacatavra/servo,A-deLuna/servo,DominoTree/servo,upsuper/servo,paulrouget/servo,anthgur/servo,seanmonstar/servo,runarberg/servo,tempbottle/servo,samfoo/servo,pyfisch/servo,mattnenterprise/servo,mrobinson/servo,avadacatavra/servo,luniv/servo,pyfisch/servo,g-k/servo,mukilan/servo,GreenRecycleBin/servo,nick-thompson/servo,jlegendary/servo,saratang/servo,DominoTree/servo,ruud-v-a/servo,brendandahl/servo,sadmansk/servo,chotchki/servo,ryancanhelpyou/servo,caldwell/servo,dati91/servo,jimberlage/servo,samfoo/servo,meh/servo,larsbergstrom/servo,avadacatavra/servo,SimonSapin/servo,ConnorGBrewster/servo,akosel/servo,mt2d2/servo,nerith/servo,zentner-kyle/servo,kindersung/servo,jlegendary/servo,cbrewster/servo,RenaudParis/servo,runarberg/servo,szeged/servo,rentongzhang/servo,tafia/servo,shrenikgala/servo,jgraham/servo,jgraham/servo,DominoTree/servo,mdibaiee/servo,metajack/servo,dhananjay92/servo,brendandahl/servo,rixrix/servo,tafia/servo,mattnenterprise/servo,GyrosOfWar/servo,michaelwu/servo,luniv/servo,larsbergstrom/servo,meh/servo,wpgallih/servo,chotchki/servo,aweinstock314/servo,pyecs/servo,wpgallih/servo,froydnj/servo,larsbergstrom/servo,tschneidereit/servo,CJ8664/servo,kindersung/servo,steveklabnik/servo,saneyuki/servo,jdramani/servo,notriddle/servo,KiChjang/servo,KiChjang/servo,samfoo/servo,j3parker/servo,dagnir/servo,cbrewster/servo,DominoTree/servo,codemac/servo,jdramani/servo,mattnenterprise/servo,s142857/servo,peterjoel/servo,juzer10/servo,brendandahl/servo,fiji-flo/servo,rixrix/servo,steveklabnik/servo,RenaudParis/servo,codemac/servo,Shraddha512/servo,samfoo/servo,steveklabnik/servo,tschneidereit/servo,bfrohs/servo,srbhklkrn/SERVOENGINE,steveklabnik/servo,dati91/servo,AnthonyBroadCrawford/servo,michaelwu/servo,fiji-flo/servo,juzer10/servo,pgonda/servo,notriddle/servo,notriddle/servo,splav/servo,tempbottle/servo,jgraham/servo,rixrix/servo,szeged/servo,mdibaiee/servo,nnethercote/servo,juzer10/servo,sadmansk/servo,bjwbell/servo,peterjoel/servo,DominoTree/servo,zentner-kyle/servo,metajack/servo,dvberkel/servo,ConnorGBrewster/servo,emilio/servo,mbrubeck/servo,luniv/servo,WriterOfAlicrow/servo,notriddle/servo,kindersung/servo,szeged/servo,vks/servo,thiagopnts/servo,ConnorGBrewster/servo,nerith/servo,anthgur/servo,KiChjang/servo,CJ8664/servo,jimberlage/servo,GyrosOfWar/servo,saratang/servo,emilio/servo,j3parker/servo,rixrix/servo,luniv/servo,sadmansk/servo,jimberlage/servo,anthgur/servo,rixrix/servo,GyrosOfWar/servo,rentongzhang/servo,akosel/servo,dagnir/servo,chotchki/servo,indykish/servo,zentner-kyle/servo,akosel/servo,fiji-flo/servo,RenaudParis/servo,anthgur/servo,indykish/servo,samfoo/servo,youprofit/servo,upsuper/servo,mt2d2/servo,thiagopnts/servo,zhangjunlei26/servo,wartman4404/servo,mukilan/servo,cbrewster/servo,caldwell/servo,nerith/servo,jgraham/servo,hyowon/servo,luniv/servo,fiji-flo/servo,zhangjunlei26/servo,KiChjang/servo,saratang/servo,rnestler/servo,rentongzhang/servo,michaelwu/servo,mdibaiee/servo,zhangjunlei26/servo,dsandeephegde/servo,dvberkel/servo,AnthonyBroadCrawford/servo,canaltinova/servo,g-k/servo,pgonda/servo,chotchki/servo,larsbergstrom/servo,wpgallih/servo,larsbergstrom/servo,luniv/servo,aweinstock314/servo,dsandeephegde/servo,bfrohs/servo,echochamber/servo,snf/servo,nrc/servo,avadacatavra/servo,nnethercote/servo,rnestler/servo,ConnorGBrewster/servo,splav/servo,j3parker/servo,samfoo/servo,akosel/servo,nerith/servo,echochamber/servo,zhangjunlei26/servo,CJ8664/servo,GreenRecycleBin/servo,tempbottle/servo,meh/servo,j3parker/servo,upsuper/servo,pyfisch/servo,thiagopnts/servo,youprofit/servo,mattnenterprise/servo,evilpie/servo,dagnir/servo,saratang/servo,mrobinson/servo,sadmansk/servo,bfrohs/servo,fiji-flo/servo,paulrouget/servo,pyfisch/servo,shrenikgala/servo,evilpie/servo,dsandeephegde/servo,upsuper/servo,cbrewster/servo,zhangjunlei26/servo,huonw/servo,metajack/servo,nnethercote/servo,rnestler/servo,michaelwu/servo,ruud-v-a/servo,aidanhs/servo,rentongzhang/servo,GreenRecycleBin/servo,notriddle/servo,wartman4404/servo,hyowon/servo,chotchki/servo,ruud-v-a/servo,dhananjay92/servo,froydnj/servo,rixrix/servo,huonw/servo,karlito40/servo,Adenilson/prototype-viewing-distance,dmarcos/servo,pyecs/servo,boghison/servo,upsuper/servo,mdibaiee/servo,michaelwu/servo,snf/servo,thiagopnts/servo,wartman4404/servo,RenaudParis/servo,jgraham/servo,aweinstock314/servo,wpgallih/servo,vks/servo,bfrohs/servo,wpgallih/servo,mattnenterprise/servo,dhananjay92/servo,deokjinkim/servo,aweinstock314/servo,saneyuki/servo,pyecs/servo,wartman4404/servo,notriddle/servo,youprofit/servo,brendandahl/servo,saneyuki/servo,dati91/servo,jdramani/servo,peterjoel/servo,aweinstock314/servo,eddyb/servo,pyfisch/servo,walac/servo,nnethercote/servo,indykish/servo,GreenRecycleBin/servo,mbrubeck/servo,juzer10/servo,mukilan/servo,anthgur/servo,g-k/servo,jlegendary/servo,peterjoel/servo,hyowon/servo,tschneidereit/servo,emilio/servo,notriddle/servo,larsbergstrom/servo,walac/servo,mt2d2/servo,dmarcos/servo,peterjoel/servo,deokjinkim/servo,szeged/servo,jlegendary/servo,avadacatavra/servo,codemac/servo,WriterOfAlicrow/servo,ruud-v-a/servo,DominoTree/servo,eddyb/servo,froydnj/servo,indykish/servo,kindersung/servo,karlito40/servo,aweinstock314/servo,metajack/servo,jdramani/servo,rentongzhang/servo,jimberlage/servo,runarberg/servo,SimonSapin/servo,jgraham/servo,steveklabnik/servo,SimonSapin/servo,hyowon/servo,splav/servo,emilio/servo,peterjoel/servo,boghison/servo,caldwell/servo,SimonSapin/servo,shrenikgala/servo,emilio/servo,emilio/servo,dvberkel/servo,sadmansk/servo,mukilan/servo,huonw/servo,GyrosOfWar/servo,mbrubeck/servo,s142857/servo,cbrewster/servo,mukilan/servo,DominoTree/servo,zentner-kyle/servo,codemac/servo,WriterOfAlicrow/servo,vks/servo,emilio/servo,mdibaiee/servo,saneyuki/servo,larsbergstrom/servo,bjwbell/servo,dati91/servo,larsbergstrom/servo,AnthonyBroadCrawford/servo,thiagopnts/servo,indykish/servo,GreenRecycleBin/servo,canaltinova/servo,jimberlage/servo,eddyb/servo,SimonSapin/servo,tempbottle/servo,notriddle/servo,akosel/servo,WriterOfAlicrow/servo,zentner-kyle/servo,youprofit/servo,bfrohs/servo,juzer10/servo,j3parker/servo,nrc/servo