From e0cd04d809ae1612a8ea706b2ac2118ca092d34f Mon Sep 17 00:00:00 2001 From: Ilija Tovilo Date: Fri, 23 Aug 2019 14:50:13 +0200 Subject: [PATCH] Add more impure functions to configuration (#2053) * Add more impure functions to configuration Closes #2050 * Change note --- src/Psalm/Internal/Codebase/Functions.php | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/Psalm/Internal/Codebase/Functions.php b/src/Psalm/Internal/Codebase/Functions.php index fa7b0720c..39c742ab9 100644 --- a/src/Psalm/Internal/Codebase/Functions.php +++ b/src/Psalm/Internal/Codebase/Functions.php @@ -271,7 +271,7 @@ class Functions 'chdir', 'chgrp', 'chmod', 'chown', 'chroot', 'closedir', 'copy', 'file_put_contents', 'fopen', 'fread', 'fwrite', 'fclose', 'touch', 'fpassthru', 'fputs', 'fscanf', 'fseek', 'ftruncate', 'fprintf', 'symlink', 'mkdir', 'unlink', 'rename', 'rmdir', 'popen', 'pclose', - 'fputcsv', 'umask', + 'fputcsv', 'umask', 'finfo_close', // stream/socket io 'stream_context_set_option', 'socket_write', 'stream_set_blocking', 'socket_close', @@ -321,6 +321,15 @@ class Functions // logging 'openlog', 'syslog', 'error_log', 'define_syslog_variables', + + // session + 'session_id', 'session_name', 'session_set_cookie_params', + + // ldap + 'ldap_set_option', + + // iterators + 'rewind', ]; if (\in_array(strtolower($function_id), $impure_functions, true)) {