savedra1 / clipse

Configurable TUI clipboard manager for Unix
MIT License
334 stars 13 forks source link

[bug] Full-system overwrite #157

Open kqvanity opened 3 days ago

kqvanity commented 3 days ago

Clipse write history to a json file in $HOME. When the system is filled to its rim, it'd attempt to write, which would cause a corruption of previous history JSON file, clipse would then crash next time you start it.

savedra1 commented 16 hours ago

Hi @kqvanity,

Thanks for raising this. To make sure I understand, are you saying that if a machine has no disk space the write operation to the history file would fail and corrupt the history file? Did you experience this personally?

I haven't tested this edge case but deleting the corrupted json file would allow it be recreated once space has been cleared. I would also suggest setting your max history limit to something small if you are prone to reaching your systems disk limit.

kqvanity commented 14 hours ago

I became more vigilant to my HOME available space. It's an obscure edge case, but just wanted to mention it.

Did you experience this personally?

I did twice.

Steps to reproduce