Those lines of code are in place for error logging.
they set session variables that contain data about each individual email being sent to allow for tracking the email progress.
the session_start() function is in place to force php to look for the session, in some servers we have had problems with php not finding the session. session_commit() is in place to force PHP to write the session data, we have run into that problem in some cases as well.
If you are not tracking email progress, you can comment out those lines if you wish.