]> git.ipfire.org Git - thirdparty/sqlite.git/commitdiff
Backslash escaping is not working right in tostr.awk on the latest ubuntu.
authordrh <drh@noemail.net>
Wed, 31 Aug 2011 17:46:50 +0000 (17:46 +0000)
committerdrh <drh@noemail.net>
Wed, 31 Aug 2011 17:46:50 +0000 (17:46 +0000)
The easiest fix is to simply not use any backslashes in the spaceanal.tcl
script.

FossilOrigin-Name: df550066657cb41bad34ac8e722b8148ab7eabfb

manifest
manifest.uuid
tool/spaceanal.tcl
tool/tostr.awk

index 4c460d652a676e826446f95614d361e1230178a0..fa2504aba773dc264148c01921870e33cadeedb7 100644 (file)
--- a/manifest
+++ b/manifest
@@ -1,5 +1,5 @@
-C Add\schecks\sto\smake\ssure\scells\sin\scorrupt\sdatabase\sfiles\s\ndo\snot\soverflow\sa\spage\swhen\sdoing\sautovacuum.\nProblem\sdetected\sby\svalgrind.
-D 2011-08-31T13:27:19.588
+C Backslash\sescaping\sis\snot\sworking\sright\sin\stostr.awk\son\sthe\slatest\subuntu.\nThe\seasiest\sfix\sis\sto\ssimply\snot\suse\sany\sbackslashes\sin\sthe\sspaceanal.tcl\nscript.
+D 2011-08-31T17:46:50.850
 F Makefile.arm-wince-mingw32ce-gcc d6df77f1f48d690bd73162294bbba7f59507c72f
 F Makefile.in d314143fa6be24828021d3f583ad37d9afdce505
 F Makefile.linux-gcc 91d710bdc4998cb015f39edf3cb314ec4f4d7e23
@@ -950,7 +950,7 @@ F tool/showjournal.c b62cecaab86a4053d944c276bb5232e4d17ece02
 F tool/showwal.c f09e5a80a293919290ec85a6a37c85a5ddcf37d9
 F tool/soak1.tcl 8d407956e1a45b485a8e072470a3e629a27037fe
 F tool/space_used.tcl f714c41a59e326b8b9042f415b628b561bafa06b
-F tool/spaceanal.tcl b91879d52bf77a1ff5382493284f429d32a63490
+F tool/spaceanal.tcl 1ee4df4e190675ba67b8c60cf304496d0021cfb4
 F tool/speedtest.tcl 06c76698485ccf597b9e7dbb1ac70706eb873355
 F tool/speedtest16.c c8a9c793df96db7e4933f0852abb7a03d48f2e81
 F tool/speedtest2.tcl ee2149167303ba8e95af97873c575c3e0fab58ff
@@ -958,10 +958,10 @@ F tool/speedtest8.c 2902c46588c40b55661e471d7a86e4dd71a18224
 F tool/speedtest8inst1.c 293327bc76823f473684d589a8160bde1f52c14e
 F tool/split-sqlite3c.tcl d9be87f1c340285a3e081eb19b4a247981ed290c
 F tool/symbols.sh caaf6ccc7300fd43353318b44524853e222557d5
-F tool/tostr.awk 11760e1b94a5d3dcd42378f3cc18544c06cfa576
+F tool/tostr.awk e75472c2f98dd76e06b8c9c1367f4ab07e122d06
 F tool/vdbe-compress.tcl d70ea6d8a19e3571d7ab8c9b75cba86d1173ff0f
 F tool/warnings.sh b7fdb2cc525f5ef4fa43c80e771636dd3690f9d2
-P 20ddfb4780b87953718f3a8e67b777dcff0e3b5e
-R 513927bc09bdb01972234dc3d07878fd
+P d0b347b412376d22e9f0770ac083dafb5e480dd0
+R b71c3db157ba0c4a396659741c76245f
 U drh
-Z 7574b78d098e12a356337eb2bfd798e6
+Z 6dc79f498e7b45dccac5e2d58d584bd0
index baf170c9f2ba6c078ce8ad901bb0cee96f5c21a3..16eff18a9f2690f4ced8685d53142e6aaacde63a 100644 (file)
@@ -1 +1 @@
-d0b347b412376d22e9f0770ac083dafb5e480dd0
\ No newline at end of file
+df550066657cb41bad34ac8e722b8148ab7eabfb
\ No newline at end of file
index bf6244e8c994c269b3f7d4cfd356bd7da6548574..13ab1af5f76c5ef82d08dd5b2ae576f5e2f1ffc6 100644 (file)
@@ -41,8 +41,7 @@ set pageSize [db one {PRAGMA page_size}]
 # queries the in-memory db to produce the space-analysis report.
 #
 sqlite3 mem :memory:
-set tabledef\
-{CREATE TABLE space_used(
+set tabledef {CREATE TABLE space_used(
    name clob,        -- Name of a table or index in the database file
    tblname clob,     -- Name of associated table
    is_index boolean, -- TRUE if it is an index, false for a table
@@ -293,16 +292,16 @@ proc subreport {title where} {
   statline {Overflow pages used} $ovfl_pages
   statline {Total pages used} $total_pages
   if {$int_unused>0} {
-    set int_unused_percent \
-         [percent $int_unused [expr {$int_pages*$pageSize}] {of index space}]
+    set int_unused_percent [
+         percent $int_unused [expr {$int_pages*$pageSize}] {of index space}]
     statline "Unused bytes on index pages" $int_unused $int_unused_percent
   }
-  statline "Unused bytes on primary pages" $leaf_unused \
-     [percent $leaf_unused [expr {$leaf_pages*$pageSize}] {of primary space}]
-  statline "Unused bytes on overflow pages" $ovfl_unused \
-     [percent $ovfl_unused [expr {$ovfl_pages*$pageSize}] {of overflow space}]
-  statline "Unused bytes on all pages" $total_unused \
-               [percent $total_unused $storage {of all space}]
+  statline "Unused bytes on primary pages" $leaf_unused [
+     percent $leaf_unused [expr {$leaf_pages*$pageSize}] {of primary space}]
+  statline "Unused bytes on overflow pages" $ovfl_unused [
+     percent $ovfl_unused [expr {$ovfl_pages*$pageSize}] {of overflow space}]
+  statline "Unused bytes on all pages" $total_unused [
+               percent $total_unused $storage {of all space}]
   return 1
 }
 
@@ -452,11 +451,9 @@ Page size in bytes
 
 Number of pages in the whole file
 }
-puts \
-"    The number of $pageSize-byte pages that go into forming the complete
+puts "    The number of $pageSize-byte pages that go into forming the complete
     database"
-puts \
-{
+puts {
 Pages that store data
 
     The number of pages that store data, either as primary B*Tree pages or
index 83c6cc1a50ad6414c1a0d89f987ea87dbf24cec4..b4f48d3db559ae9624ce82a328ebdef9b966e0f7 100644 (file)
@@ -3,7 +3,6 @@
 # Convert input text into a C string
 #
 {
-  gsub(/\\/,"\\\\");
   gsub(/\"/,"\\\"");
   print "\"" $0 "\\n\"";
 }