Binary tree problem(find all root to leaf path sum )

here is my code
its giving segmentation error

please help

@gulatigarvita08 check this