|
@@ 482-485 (lines=4) @@
|
| 479 |
|
|
| 480 |
|
spip_log( "Copier ".count($tables)." tables de '$serveur_source' vers '$serveur_dest'",'dump.'._LOG_INFO_IMPORTANTE); |
| 481 |
|
|
| 482 |
|
if (!$inserer_copie = charger_fonction($fonction_base_inserer,$racine_fonctions, true)) { |
| 483 |
|
spip_log( "Fonction '{$racine_fonctions}_$fonction_base_inserer' inconnue. Abandon",'dump.'._LOG_INFO_IMPORTANTE); |
| 484 |
|
return true; // echec mais on a fini, donc true |
| 485 |
|
} |
| 486 |
|
if (!$preparer_table_dest = charger_fonction('preparer_table_dest',$racine_fonctions, true)) { |
| 487 |
|
spip_log( "Fonction '{$racine_fonctions}_$preparer_table_dest' inconnue. Abandon",'dump.'._LOG_INFO_IMPORTANTE); |
| 488 |
|
return true; // echec mais on a fini, donc true |
|
@@ 486-489 (lines=4) @@
|
| 483 |
|
spip_log( "Fonction '{$racine_fonctions}_$fonction_base_inserer' inconnue. Abandon",'dump.'._LOG_INFO_IMPORTANTE); |
| 484 |
|
return true; // echec mais on a fini, donc true |
| 485 |
|
} |
| 486 |
|
if (!$preparer_table_dest = charger_fonction('preparer_table_dest',$racine_fonctions, true)) { |
| 487 |
|
spip_log( "Fonction '{$racine_fonctions}_$preparer_table_dest' inconnue. Abandon",'dump.'._LOG_INFO_IMPORTANTE); |
| 488 |
|
return true; // echec mais on a fini, donc true |
| 489 |
|
} |
| 490 |
|
|
| 491 |
|
if (!lire_fichier($status_file, $status) |
| 492 |
|
OR !$status = unserialize($status)) |
|
@@ 502-505 (lines=4) @@
|
| 499 |
|
|
| 500 |
|
// si init pas encore faite, vider les tables du serveur destination |
| 501 |
|
if (!$initialisation_copie) { |
| 502 |
|
if (!$vider_tables_destination_copie = charger_fonction('vider_tables_destination_copie',$racine_fonctions, true)) { |
| 503 |
|
spip_log( "Fonction '{$racine_fonctions}_vider_tables_destination_copie' inconnue. Abandon",'dump.'._LOG_INFO_IMPORTANTE); |
| 504 |
|
return true; // echec mais on a fini, donc true |
| 505 |
|
} |
| 506 |
|
$vider_tables_destination_copie($tables, $no_erase_dest, $serveur_dest); |
| 507 |
|
$status["dump_status_copie"]='ok'; |
| 508 |
|
ecrire_fichier($status_file,serialize($status)); |
|
@@ 620-625 (lines=6) @@
|
| 617 |
|
ecrire_fichier($status_file,serialize($status)); |
| 618 |
|
} |
| 619 |
|
|
| 620 |
|
if ($detruire_copieur_si_besoin = charger_fonction('detruire_copieur_si_besoin',$racine_fonctions, true)) { |
| 621 |
|
$detruire_copieur_si_besoin($serveur_dest); |
| 622 |
|
} |
| 623 |
|
else { |
| 624 |
|
spip_log( "Fonction '{$racine_fonctions}_detruire_copieur_si_besoin' inconnue.",'dump.'._LOG_INFO_IMPORTANTE); |
| 625 |
|
} |
| 626 |
|
|
| 627 |
|
// OK, copie complete |
| 628 |
|
return true; |