Projet

Général

Profil

Révision 582db59d

Ajouté par Assos Assos il y a plus de 8 ans

Update Drupal core to version 7.40

Voir les différences:

drupal7/includes/database/mysql/database.inc
51 51
      // Because MySQL's prepared statements skip the query cache, because it's dumb.
52 52
      PDO::ATTR_EMULATE_PREPARES => TRUE,
53 53
    );
54
    if (defined('PDO::MYSQL_ATTR_MULTI_STATEMENTS')) {
55
      // An added connection option in PHP 5.5.21+ to optionally limit SQL to a
56
      // single statement like mysqli.
57
      $connection_options['pdo'] += array(PDO::MYSQL_ATTR_MULTI_STATEMENTS => FALSE);
58
    }
54 59

  
55 60
    parent::__construct($dsn, $connection_options['username'], $connection_options['password'], $connection_options['pdo']);
56 61

  
......
78 83
    $connection_options['init_commands'] += array(
79 84
      'sql_mode' => "SET sql_mode = 'ANSI,STRICT_TRANS_TABLES,STRICT_ALL_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER'",
80 85
    );
81
    // Set connection options.
82
    $this->exec(implode('; ', $connection_options['init_commands']));
86
    // Execute initial commands.
87
    foreach ($connection_options['init_commands'] as $sql) {
88
      $this->exec($sql);
89
    }
83 90
  }
84 91

  
85 92
  public function __destruct() {

Formats disponibles : Unified diff