summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authormsvensson@pilot.blaudden <>2007-04-19 21:30:46 +0200
committermsvensson@pilot.blaudden <>2007-04-19 21:30:46 +0200
commitda93a36a0e6a137861d9bc6b1f04b86d89e8c1e3 (patch)
tree21ba3b2425c7c4650f26c45bb531d691c3780770 /scripts
parent2c95135c8dfa9bf577a1c5faee9a62eeac240f95 (diff)
downloadmariadb-git-da93a36a0e6a137861d9bc6b1f04b86d89e8c1e3.tar.gz
mysql_upgrade portability fixes
Diffstat (limited to 'scripts')
-rw-r--r--scripts/comp_sql.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/scripts/comp_sql.c b/scripts/comp_sql.c
index 328dab0cf13..53359d384c1 100644
--- a/scripts/comp_sql.c
+++ b/scripts/comp_sql.c
@@ -106,6 +106,15 @@ int main(int argc, char *argv[])
curr++;
}
}
+ if (*(curr-1) != '\n')
+ {
+ /*
+ Some compilers have a max string length,
+ insert a newline at every 512th char in long
+ strings
+ */
+ fprintf(out, "\"\n\"");
+ }
}
fprintf(out, "\\\n\"};\n");