In the event lockdir is not specified in the koha-conf.xml file which will occur for old installations, default the lockdir to a sensible default (/var/lock). --- misc/migration_tools/rebuild_zebra.pl | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/misc/migration_tools/rebuild_zebra.pl b/misc/migration_tools/rebuild_zebra.pl index e18725c..8b77686 100755 --- a/misc/migration_tools/rebuild_zebra.pl +++ b/misc/migration_tools/rebuild_zebra.pl @@ -143,7 +143,9 @@ my ($biblioitemnumbertagfield,$biblioitemnumbertagsubfield) = &GetMarcFromKohaFi # We need to create our own lock directory which incorporates the database instance # we are indexing to facilitate multiple instances on the same machine. -my $lockdir = C4::Context->config("lockdir") . "/koha_rebuild_zebra_" . C4::Context->config("database"); +my $lockdir = C4::Context->config("lockdir"); +$lockdir = "/var/lock" if $lockdir == ""; +$lockdir .= ("/koha_rebuild_zebra_" . C4::Context->config("database")); mkpath($lockdir, 0, 0755) unless (-d $lockdir); my $lockfile = $lockdir . "/lock"; -- 1.7.9.5 _______________________________________________ Koha-patches mailing list Koha-patches@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-patches website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/