try system instead of exec