Skip to content

Instantly share code, notes, and snippets.

@solepixel
Created August 29, 2015 13:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save solepixel/428b316e964c005e2799 to your computer and use it in GitHub Desktop.
Save solepixel/428b316e964c005e2799 to your computer and use it in GitHub Desktop.
CodeIgniter function with @ symbol
<?php
// Lines 706-721 of system/libraries/Session.php
function _unserialize($data)
{
$data = @unserialize(strip_slashes($data));
if (is_array($data))
{
foreach ($data as $key => $val)
{
$data[$key] = str_replace('{{slash}}', '\\', $val);
}
return $data;
}
return str_replace('{{slash}}', '\\', $data);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment