this post was submitted on 02 Oct 2023
1418 points (96.8% liked)

Programmer Humor

19660 readers
358 users here now

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

founded 1 year ago
MODERATORS
 
you are viewing a single comment's thread
view the rest of the comments
[–] [email protected] 12 points 1 year ago* (last edited 1 year ago) (2 children)

I don't know about dangerous, but case-insensitive Unicode comparison is annoying, expensive and probably prone to footguns compared to a simple byte-for-byte equality check.

Obviously, it can be done, but I guess Linux devs don't consider it worthwhile.

(And yes, all modern filesystems support Unicode. Linux stores them as arbitrary bytes, Apple's HFS uses... some special bullshit, and Windows uses UTF-16.)

[–] [email protected] 1 points 1 year ago

Meanwhile fishshell:

[–] [email protected] 1 points 1 year ago (1 children)

so if linux stores file names as arbitrary bytes them could I modify a ext4 fs to include a / in a file name

[–] [email protected] 2 points 1 year ago

If you did it would likely break something as it's one of only two characters not allowed in a file name (the other being null).

You can do a lot of funky stuff within the rules though, think about control characters, non-printing characters, newlines, homographs, emojis etc. and go forth and make your file system chaos!