| Summary: | shell history file is overwritten after every command | ||
|---|---|---|---|
| Product: | Busybox | Reporter: | Andre Klapper <a9016009> |
| Component: | Other | Assignee: | unassigned |
| Status: | RESOLVED DUPLICATE | ||
| Severity: | minor | CC: | busybox-cvs |
| Priority: | P5 | ||
| Version: | unspecified | ||
| Target Milestone: | --- | ||
| Hardware: | PC | ||
| OS: | Linux | ||
| URL: | https://bugs.maemo.org/show_bug.cgi?id=4174 | ||
| Host: | Target: | ||
| Build: | |||
| Attachments: | Patch: make history saving/loading concurrent-safe | ||
|
Description
Andre Klapper
2009-03-05 12:49:11 UTC
Created attachment 181 [details]
Patch: make history saving/loading concurrent-safe
Please try this patch.
It makes the following changes:
* all history writes always append (not overwrite) history files
* they reload history if they detect that file length has changed since last
write
* they trim history file only when it grows 4 times longer thna MAXLINES
* they do this atomically by creating new file and renaming it to old.
|