- lire_fichier(_DIR_TMP . 'stp_actions.txt', $contenu);
- $infos = unserialize($contenu);
- $this->end = $infos['todo'];
- $this->work = $infos['work'];
- $this->done = $infos['done'];
- $this->err = $infos['err'];
- $this->lock = $infos['lock'];
+ if (
+ lire_fichier(_DIR_TMP . 'stp_actions.txt', $contenu)
+ and $contenu
+ and $infos = unserialize($contenu)
+ and is_array($infos)
+ ) {
+ $this->end = $infos['todo'];
+ $this->work = $infos['work'];
+ $this->done = $infos['done'];
+ $this->err = $infos['err'];
+ $this->lock = $infos['lock'];
+ }