note 115519 deleted from function.exit by mazzanet
| From: | mazzanet@php.net | Date: | Sun, 10 Aug 2014 09:10:30 +0000 |
| Subject: | note 115519 deleted from function.exit by mazzanet | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-200154@lists.php.net to get a copy of this message | ||
Note Submitter: zsolt dot trenyik at gmail dot com
----
It seems to be obvious, but was not clear for me for the first time: if you call exit function from
a function, it won't return, just stops without any further step. This may be dangeous if you
would have some important steps in the function code which have to be done by hand, e.g. database
rollback calls, or anything won't be not done automatically by the engine (database connection
close for example)