Fix invalid-read to freed memory in ttl-iterator
Fix invalid-read to freed memory in ttl-iterator

Summary: value function in ttl-iterator was returning string which would have been freed before its usage as a slice. Thanks valgrind!

Test Plan: valgrind ./ttl_test

Reviewers: dhruba, haobo, sheki, vamsi

Reviewed By: haobo

CC: leveldb

Differential Revision: https://reviews.facebook.net/D10635

lgscofield/rocksdb,fengshao0907/rocksdb,tsheasha/rocksdb,amyvmiwei/rocksdb,Andymic/rocksdb,Andymic/rocksdb,caijieming-baidu/rocksdb,norton/rocksdb,amyvmiwei/rocksdb,zhangpng/rocksdb,Andymic/rocksdb,JohnPJenkins/rocksdb,NickCis/rocksdb,SunguckLee/RocksDB,lgscofield/rocksdb,RyanTech/rocksdb,luckywhu/rocksdb,kaschaeffer/rocksdb,SunguckLee/RocksDB,wat-ze-hex/rocksdb,wlqGit/rocksdb,caijieming-baidu/rocksdb,SunguckLee/RocksDB,norton/rocksdb,JohnPJenkins/rocksdb,ylong/rocksdb,msb-at-yahoo/rocksdb,alihalabyah/rocksdb,tizzybec/rocksdb,skunkwerks/rocksdb,wat-ze-hex/rocksdb,IMCG/RcoksDB,wenduo/rocksdb,vashstorm/rocksdb,flabby/rocksdb,JohnPJenkins/rocksdb,caijieming-baidu/rocksdb,zhangpng/rocksdb,rDSN-Projects/rocksdb.replicated,vashstorm/rocksdb,mbarbon/rocksdb,jalexanderqed/rocksdb,norton/rocksdb,temicai/rocksdb,zhangpng/rocksdb,msb-at-yahoo/rocksdb,wat-ze-hex/rocksdb,RyanTech/rocksdb,bbiao/rocksdb,dkorolev/rocksdb,tschottdorf/rocksdb,JackLian/rocksdb,fengshao0907/rocksdb,msb-at-yahoo/rocksdb,flabby/rocksdb,siddhartharay007/rocksdb,luckywhu/rocksdb,wlqGit/rocksdb,JohnPJenkins/rocksdb,RyanTech/rocksdb,JackLian/rocksdb,siddhartharay007/rocksdb,JoeWoo/rocksdb,tizzybec/rocksdb,NickCis/rocksdb,Andymic/rocksdb,fengshao0907/rocksdb,facebook/rocksdb,OverlordQ/rocksdb,wat-ze-hex/rocksdb,biddyweb/rocksdb,zhangpng/rocksdb,fengshao0907/rocksdb,jalexanderqed/rocksdb,NickCis/rocksdb,vmx/rocksdb,bbiao/rocksdb,rDSN-Projects/rocksdb.replicated,virtdb/rocksdb,kaschaeffer/rocksdb,tsheasha/rocksdb,skunkwerks/rocksdb,Vaisman/rocksdb,tsheasha/rocksdb,biddyweb/rocksdb,vmx/rocksdb,virtdb/rocksdb,tizzybec/rocksdb,NickCis/rocksdb,IMCG/RcoksDB,jalexanderqed/rocksdb,IMCG/RcoksDB,RyanTech/rocksdb,biddyweb/rocksdb,OverlordQ/rocksdb,lgscofield/rocksdb,JoeWoo/rocksdb,JackLian/rocksdb,vmx/rocksdb,siddhartharay007/rocksdb,NickCis/rocksdb,JoeWoo/rocksdb,makelivedotnet/rocksdb,IMCG/RcoksDB,skunkwerks/rocksdb,ylong/rocksdb,wskplho/rocksdb,vashstorm/rocksdb,rDSN-Projects/rocksdb.replicated,zhangpng/rocksdb,facebook/rocksdb,OverlordQ/rocksdb,luckywhu/rocksdb,makelivedotnet/rocksdb,RyanTech/rocksdb,facebook/rocksdb,luckywhu/rocksdb,dkorolev/rocksdb,JohnPJenkins/rocksdb,hobinyoon/rocksdb,temicai/rocksdb,tizzybec/rocksdb,caijieming-baidu/rocksdb,tizzybec/rocksdb,ryneli/rocksdb,facebook/rocksdb,Applied-Duality/rocksdb,makelivedotnet/rocksdb,vmx/rocksdb,hobinyoon/rocksdb,alihalabyah/rocksdb,dkorolev/rocksdb,tizzybec/rocksdb,IMCG/RcoksDB,anagav/rocksdb,temicai/rocksdb,temicai/rocksdb,sorphi/rocksdb,flabby/rocksdb,wskplho/rocksdb,wat-ze-hex/rocksdb,anagav/rocksdb,ryneli/rocksdb,Vaisman/rocksdb,Applied-Duality/rocksdb,wlqGit/rocksdb,Vaisman/rocksdb,vmx/rocksdb,facebook/rocksdb,msb-at-yahoo/rocksdb,hobinyoon/rocksdb,JackLian/rocksdb,hobinyoon/rocksdb,rDSN-Projects/rocksdb.replicated,Applied-Duality/rocksdb,msb-at-yahoo/rocksdb,jalexanderqed/rocksdb,Andymic/rocksdb,zhangpng/rocksdb,wenduo/rocksdb,makelivedotnet/rocksdb,virtdb/rocksdb,mbarbon/rocksdb,wlqGit/rocksdb,geraldoandradee/rocksdb,makelivedotnet/rocksdb,bbiao/rocksdb,vashstorm/rocksdb,mbarbon/rocksdb,sorphi/rocksdb,JohnPJenkins/rocksdb,anagav/rocksdb,alihalabyah/rocksdb,rDSN-Projects/rocksdb.replicated,alihalabyah/rocksdb,bbiao/rocksdb,kaschaeffer/rocksdb,mbarbon/rocksdb,anagav/rocksdb,ylong/rocksdb,JackLian/rocksdb,tschottdorf/rocksdb,Vaisman/rocksdb,ylong/rocksdb,anagav/rocksdb,vashstorm/rocksdb,kaschaeffer/rocksdb,alihalabyah/rocksdb,amyvmiwei/rocksdb,bbiao/rocksdb,msb-at-yahoo/rocksdb,rDSN-Projects/rocksdb.replicated,bbiao/rocksdb,jalexanderqed/rocksdb,OverlordQ/rocksdb,caijieming-baidu/rocksdb,wenduo/rocksdb,tschottdorf/rocksdb,wenduo/rocksdb,geraldoandradee/rocksdb,SunguckLee/RocksDB,wskplho/rocksdb,jalexanderqed/rocksdb,bbiao/rocksdb,Andymic/rocksdb,geraldoandradee/rocksdb,siddhartharay007/rocksdb,amyvmiwei/rocksdb,siddhartharay007/rocksdb,jalexanderqed/rocksdb,JoeWoo/rocksdb,NickCis/rocksdb,skunkwerks/rocksdb,ryneli/rocksdb,tsheasha/rocksdb,caijieming-baidu/rocksdb,geraldoandradee/rocksdb,SunguckLee/RocksDB,vmx/rocksdb,ryneli/rocksdb,flabby/rocksdb,fengshao0907/rocksdb,virtdb/rocksdb,dkorolev/rocksdb,lgscofield/rocksdb,norton/rocksdb,wat-ze-hex/rocksdb,wenduo/rocksdb,bbiao/rocksdb,wskplho/rocksdb,norton/rocksdb,wskplho/rocksdb,SunguckLee/RocksDB,ryneli/rocksdb,luckywhu/rocksdb,luckywhu/rocksdb,tizzybec/rocksdb,amyvmiwei/rocksdb,ylong/rocksdb,kaschaeffer/rocksdb,sorphi/rocksdb,flabby/rocksdb,OverlordQ/rocksdb,siddhartharay007/rocksdb,amyvmiwei/rocksdb,virtdb/rocksdb,Vaisman/rocksdb,rDSN-Projects/rocksdb.replicated,wenduo/rocksdb,OverlordQ/rocksdb,facebook/rocksdb,ryneli/rocksdb,geraldoandradee/rocksdb,skunkwerks/rocksdb,temicai/rocksdb,anagav/rocksdb,virtdb/rocksdb,amyvmiwei/rocksdb,wat-ze-hex/rocksdb,ylong/rocksdb,wlqGit/rocksdb,sorphi/rocksdb,JoeWoo/rocksdb,Andymic/rocksdb,anagav/rocksdb,fengshao0907/rocksdb,RyanTech/rocksdb,fengshao0907/rocksdb,tsheasha/rocksdb,wenduo/rocksdb,wlqGit/rocksdb,geraldoandradee/rocksdb,lgscofield/rocksdb,dkorolev/rocksdb,sorphi/rocksdb,biddyweb/rocksdb,Applied-Duality/rocksdb,hobinyoon/rocksdb,Applied-Duality/rocksdb,flabby/rocksdb,skunkwerks/rocksdb,vashstorm/rocksdb,ylong/rocksdb,Vaisman/rocksdb,ryneli/rocksdb,sorphi/rocksdb,lgscofield/rocksdb,tsheasha/rocksdb,tschottdorf/rocksdb,SunguckLee/RocksDB,vashstorm/rocksdb,JohnPJenkins/rocksdb,tschottdorf/rocksdb,NickCis/rocksdb,norton/rocksdb,tsheasha/rocksdb,zhangpng/rocksdb,wenduo/rocksdb,kaschaeffer/rocksdb,vmx/rocksdb,luckywhu/rocksdb,alihalabyah/rocksdb,facebook/rocksdb,IMCG/RcoksDB,flabby/rocksdb,mbarbon/rocksdb,geraldoandradee/rocksdb,tsheasha/rocksdb,wat-ze-hex/rocksdb,wlqGit/rocksdb,alihalabyah/rocksdb,mbarbon/rocksdb,RyanTech/rocksdb,hobinyoon/rocksdb,biddyweb/rocksdb,sorphi/rocksdb,SunguckLee/RocksDB,hobinyoon/rocksdb,Vaisman/rocksdb,norton/rocksdb,temicai/rocksdb,vmx/rocksdb,tschottdorf/rocksdb,siddhartharay007/rocksdb,JoeWoo/rocksdb,makelivedotnet/rocksdb,lgscofield/rocksdb,wskplho/rocksdb,IMCG/RcoksDB,biddyweb/rocksdb,mbarbon/rocksdb,dkorolev/rocksdb,facebook/rocksdb,makelivedotnet/rocksdb,JoeWoo/rocksdb,Applied-Duality/rocksdb,biddyweb/rocksdb,norton/rocksdb,skunkwerks/rocksdb,kaschaeffer/rocksdb,temicai/rocksdb,OverlordQ/rocksdb,JackLian/rocksdb,Applied-Duality/rocksdb,caijieming-baidu/rocksdb,hobinyoon/rocksdb,JackLian/rocksdb,dkorolev/rocksdb,wskplho/rocksdb,Andymic/rocksdb,virtdb/rocksdb