eminence / eminence/procfs

Textual information from /proc should not be exposed as String

Open
#349 2 comments 0 reactions 0 assignees View on GitHub
Dominant language
Rust
Stars
445
Forks
134
PR merge metrics
No merged PRs in 30d

Description

The kernel does not care about proper UTF-8 encodings, so conversion into `String` are always lossy operations.
`Process.cmdline()` should return a `Vec`, `Stat.comm` should be an `OsString`. These are the only examples I noticed when checking whether I could replace my own code with `procfs` – there are probably quite a few other examples.

Would you accept a PR that replaces those uses of `String` with `OsString`? I am aware that this would require an API version bump – if you don't want to do that, I could also do a patch that only adds fields and methods.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.