diff options
| author | Yann E. MORIN <[email protected]> | 2012-04-09 12:49:10 +0000 |
|---|---|---|
| committer | Michal Marek <[email protected]> | 2012-05-15 22:13:11 +0000 |
| commit | d6686da814c884e341d3bd8aa54947c91cb678be (patch) | |
| tree | 795f9f0c4d164ae758b31e9998bc3ca78f94b3a4 /tools/perf/util/trace-event-scripting.c | |
| parent | kbuild: all{no,yes,mod,def,rand}config only read files when instructed to. (diff) | |
| download | kernel-d6686da814c884e341d3bd8aa54947c91cb678be.tar.gz kernel-d6686da814c884e341d3bd8aa54947c91cb678be.zip | |
scripts/config: properly report and set string options
Currently, scripts/config removes the leading double-quote from
string options, but leaves the trailing double-quote.
Also, double-quotes in a string are escaped, but scripts/config
does not unescape those when printing
Finally, scripts/config does not escape double-quotes when setting
string options.
Eg. the current behavior:
$ grep -E '^CONFIG_FOO=' .config
CONFIG_FOO="Bar \"Buz\" Meh"
$ ./scripts/config -s FOO
Bar \"Buz\" Meh"
$ ./scripts/config --set-str FOO 'Alpha "Bravo" Charlie'
$ grep -E '^CONFIG_FOO=' .config
CONFIG_FOO="Alpha "Bravo" Charlie"
Fix those three, giving this new behavior:
$ grep -E '^CONFIG_FOO=' .config
CONFIG_FOO="Bar \"Buz\" Meh"
$ ./scripts/config -s FOO
Bar "Buz" Meh
$ ./scripts/config --set-str FOO 'Alpha "Bravo" Charlie'
$ grep -E '^CONFIG_FOO=' .config
CONFIG_FOO="Alpha \"Bravo\" Charlie"
Signed-off-by: "Yann E. MORIN" <[email protected]>
Acked-by: Andi Kleen <[email protected]>
Signed-off-by: Michal Marek <[email protected]>
Diffstat (limited to 'tools/perf/util/trace-event-scripting.c')
0 files changed, 0 insertions, 0 deletions
