@@ -1260,7 +1260,7 @@ def __cleanupOptions():
12601260 if conf .optimize :
12611261 #conf.predictOutput = True
12621262 conf .keepAlive = True
1263- conf .nullConnection = not conf .textOnly
1263+ conf .nullConnection = not any ([ conf .textOnly , conf . titles ])
12641264 conf .threads = 3 if conf .threads < 3 else conf .threads
12651265
12661266 if conf .data :
@@ -1272,7 +1272,7 @@ def __cleanupOptions():
12721272 if conf .dbms :
12731273 conf .dbms = conf .dbms .capitalize ()
12741274
1275- if conf .optimize and any ([conf .data , conf .textOnly ]):
1275+ if conf .optimize and any ([conf .data , conf .textOnly , conf . titles ]):
12761276 conf .nullConnection = False
12771277
12781278 debugMsg = "turning off --null-connection switch used indirectly by switch -o"
@@ -1668,6 +1668,10 @@ def __basicOptionValidation():
16681668 errMsg = "switch --text-only is incompatible with switch --null-connection"
16691669 raise sqlmapSyntaxException , errMsg
16701670
1671+ if conf .titles and conf .nullConnection :
1672+ errMsg = "switch --titles is incompatible with switch --null-connection"
1673+ raise sqlmapSyntaxException , errMsg
1674+
16711675 if conf .data and conf .nullConnection :
16721676 errMsg = "switch --data is incompatible with switch --null-connection"
16731677 raise sqlmapSyntaxException , errMsg
0 commit comments