What's new
  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

Diversion Diversion crashes every few days

Wouldn't it be easy to replace the single quotes with double quotes when enclosing the string assigned to the adsCountLM variable?

View attachment 65166

If there's any chance that the string could also contain double-quotes, it's easy to escape those.
For example:
View attachment 65167

Or, is there some specific technical reason that the code must use single quotes to assign the variable?
I haven't looked closer at the rest of the code, so perhaps there's a reason for it.

Just my 2 cents.
Storing a variable that contains special chars is always a challenge - especially if you want to grep that exact string later on. Using a single quote for the Dnsmasq line worked for years now. I am unwilling to change it.
I wish any important input field would strip special characters like these. It's such a bad practice to allow these. Or nulls. Found that out the hard way when people were naming their USB drives a null value, which subsequently became a required field name in AMTM when formatting a new drive.
Exactly my point. Next thing users want is blancs in domain and email names.
Some things are simply not meant to be or cannot be done.
 
Last edited:
Storing a variable that contains special chars is always a challenge - especially if you want to grep that exact string later on. Using a single quote for the Dnsmasq line worked for years now. I am unwilling to change it.
Ah, I understand. It's a case of "risk vs. reward" trade-off. You're afraid that fixing one thing might break something else, especially when the fix addresses a small use case (e.g., using apostrophes) that does not follow the standard naming conventions that are considered good industry practice; hence, the unwillingness to take the risk for little benefit.
 
Wouldn't it be easy to replace the single quotes with double quotes when enclosing the string assigned to the adsCountLM variable?
I'm testing this with my main and test routers, looks like it has no negative affect so far even when a single quote is used in the dnsmasq.log 👍
Let me run it that way for a few days here before I release an update.
 

Support SNBForums w/ Amazon

If you'd like to support SNBForums, just use this link and buy anything on Amazon. Thanks!

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!
Back
Top