Document example is wrong with usage of "session.use_strict_mode" according to RFC (says: "warning error for session_id() when use_strice_mode=1" on https://wiki.php.net/rfc/strict_sessions).
So, this directive affects "session_id()" not "session_start()". So usage must be like this;
<?php
// first set ini
ini_set('session.use_strict_mode', '0');
// and
session_id($sid);
// then
// maybe run this: ini_restore('session.use_strict_mode');
// then go on...
?>
Refs (ctrl+f & use_strict_mode);
https://wiki.php.net/rfc/strict_sessions
https://wiki.php.net/rfc/session-create-id
http://php.net/manual/en/function.session-id.php#119997