Commit a27ffef3 authored by Mike Hibler's avatar Mike Hibler
Browse files

Fix to account for inserts that are now "insert ignore"s

parent f51f7cd5
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
# #
# EMULAB-COPYRIGHT # EMULAB-COPYRIGHT
# Copyright (c) 2000-2002, 2006 University of Utah and the Flux Group. # Copyright (c) 2000-2002, 2006, 2008 University of Utah and the Flux Group.
# All rights reserved. # All rights reserved.
# #
...@@ -132,7 +132,7 @@ sub read_sitevars($$) { ...@@ -132,7 +132,7 @@ sub read_sitevars($$) {
while(<FH>) { while(<FH>) {
my ($name, $val, $dval, $desc); my ($name, $val, $dval, $desc);
if (/^INSERT INTO `?sitevariables`?/) { if (/^INSERT( IGNORE)? INTO `?sitevariables`?/) {
# #
# Either match NULL, or # Either match NULL, or
# a quote followed by some number of: # a quote followed by some number of:
...@@ -141,7 +141,7 @@ sub read_sitevars($$) { ...@@ -141,7 +141,7 @@ sub read_sitevars($$) {
# followed by a closed quote. # followed by a closed quote.
# #
my $match = "^(('([^\\']|(\\\\.))*')|(NULL))"; my $match = "^(('([^\\']|(\\\\.))*')|(NULL))";
s/^INSERT INTO `?sitevariables`? VALUES \(//; s/^INSERT( IGNORE)? INTO `?sitevariables`? VALUES \(//;
($name) = /${match},/; ($name) = /${match},/;
s/${match},// or die "bad parse $_"; s/${match},// or die "bad parse $_";
($val) = /${match},/; ($val) = /${match},/;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment