add before fork