fixed segfault on php 5.5.3
save server env too