add validation and roll back feature
1. add large file seg_head validation check
2. roll back write when write failed or client abort
Merge pull request #254 from zhcn381/upstream

add validation and roll back feature
allow to intercept responses with status 300.
Merge pull request #255 from hnlq715/master

Upstream: allow to intercept responses with status 300.
for pull test