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

Programmer Humor

19572 readers
1533 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
[–] Honytawk@lemmy.zip 11 points 1 year ago (2 children)

Why would case sensitive path names be considered dangerous?

[–] colonial@lemmy.world 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.)

[–] MenacingPerson@lemm.ee 1 points 1 year ago

Meanwhile fishshell:

[–] lnee@lemm.ee 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

[–] kattfisk@lemmy.dbzer0.com 1 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!