The title of this post reminds me of a favorite quote "Write code as if the next person to maintain it is a homicidal maniac who knows where you live!"
HN user
wpollock
Car: You look tired. There's a motel in 3 miles.
Car: You appear to be suffering from acne. Try Zit-away, available at the convenience store in 2.4 kilometers.
Car: Facial recognition failed. Car is now disabled. Contact your car dealer to reenable vehicle.
Should be using strcpy_s or strncpy_s
These functions are optional in the C standard and not always present. AFAIK, they are not included in glibc as of 2025.
TIL! Thanks!
Stéphane (not "M") Chazelas is a genius. I have written him several times over the past 30 years, encouraging him to write a book about shell, POSIX, and other topics that he is an expert in. He writes very well too. I fear we will all be the poorer if/when he retires.
This article is a bit misleading. Linux kernel programming uses C, but not the C standard library and never has. The string functions discussed here are "helper" functions included in the kernel and are not part of the standard library.
The C standard library doesn't have strscpy or the others; it still has strncpy.
One point of clarification: with git, "global" means per-user, not "machine-wide. (I never understood why "--global" wasn't better named, maybe "--user".) That's why these pathnames are in a user's home (the "~" means the current user's home directory).
Machine-wide configuration is called "system" in git, and generally lives under "/etc".
There are laws in place forbidding government agencies from merging together datasets.
This is an excellent point. In my opinion, such laws are a good idea. Most of the time, policy decisions should not require IRS data. (Or other personal data.)
But to get around such laws, the government asks citizens to provide that data a second time (in the census). And sometimes it's asked yet again on other forms. This seems to defeat the purpose of those laws.
I can see that federal disaster aid might need to know if some area needs more or less aid, depending on the wealth of the area receiving aid. If aid is given to individuals, the have a need to know the individuals' income.
When there is a reasonable need to know, I would prefer the government use the much more accurate IRS data, rather than ask for people's income multiple times. The laws preventing merging federal datasets could be rethought, given what is now known about preserving privacy mathematically. I would like to see specific exemptions made, with the provided data properly anonymized to preserve privacy while serving the legitimate purpose for which the data was requested. The use of such data should require a request to congress for it.
Are you saying the census shouldn't collect any data that people wouldn't be comfortable publishing? Because that's a recipe for a census that is far less useful for helping the country make useful decisions.
I'll say that. The state representatives should provide congress and the president any data needed to inform policy decisions about the people they represent. And as others have pointed out, other departments and agencies (such as the IRS) have most of the rest of the data required to make policy decisions.
Except for gerrymandering purposes, I fail to see why income, party affiliations, etc., is useful for the purpose the census was created for.
The Sahara desert. It's not only repetitive but it repeats itself too as well.
These gems are brought to you by the department of redundancy department.
One of several reasons to partition a large volume into smaller ones. At least, back then.
For what it's worth, in the U.S. at least you can connect to your local library with an app named "libby". I used this frequently on my Android phone to download books and magazines, and you can connect with the InterLibrary Loan system too. My use of the public library is much, much higher than before, when I had to travel to the physical library branch to check out books or read magazines.
I wonder how many readers realized your joke here. For the ones who didn't, the 4-byte "magic number" that identifies Java .class files, in hex, spell "CAFEBABE".
This. Today, well-meaning doctors cannot spend more than 5-10 minutes between seeing patients. Medical shows on TV show teams of physicians working on one or two patients per week. The reality in my part of the world is that each doctor sees 10 or so patients each day, and are not available for phone calls. (Even in 2026 my parents can reach their doctors by phone, and they spend the time to chat. But they are in New York and I live in Florida. )
I have seen my current PC doctor for 25 years now and he knows me well enough to spot significant changes. But he's retiring in a few months and I have no idea how to find a new doctor. My current doctor has no recommendations for me. (I'm not asking here for any if that's what this sounds like.)
Do you know how to operate a punch card?
I remember! You created a control card, with tab stops and other controls, wrapped it around a control drum, and then had an easy time punching your source FORTRAN!
I just looked and found my old control drum, in the back of my junk drawer. But I can't find an old punch card machine in there, most have lost it somehow.
Very nice write up! I am a fan of Rust and have little exposure to Go. That said, a couple of very minor points:
cargo audit is not built-in, it is 3rd party. (The comparison table near the top isn't clear about that, and the following text stating more is built-in for Rust than for Go might be confusing. I would suggest adding an asterisk to mark built-ins in that table.)
cargo watch has been in "maintenance mode" for some time. The author of that suggests cargo bacon instead.
Typescript is only a linter...
I never thought of Typescript (TS) that way. I believe TS is a language addition that enabled smarter JavaScript linters; TS is not a linter program per se.
However, TS is more than that now. The extra annotations enable optimizing transpilers and even compilers (to WASM, for instance). This makes TS much more than just a better linter; I think of TS as a better language.
Theres no reason to ship TS to an end user browser.
As things are now, developers write code in TypeScript, then debug and update code in Javascript. It might not be much of a reason, but a single language throughout is surely easier on developers and maintainers.
Because "it doesn't exist". It's just a layer on top of js, ...
C++ was originally a layer on top of C. The first C++ compiler, "cfront" was actually a transpiler to C.
There is nothing preventing TypeScript from becoming "native" in a similar way.
Long ago, I had the insight that not all users are equally technically proficient. Some had the chops to fix some problems if given sufficient information. Other users would be confused with too much detail.
I was writing code for AT&T (in the 1980s), and we were our own customer. So I wrote the error routines to check an environment variable and provide different error messages for different types of users: developers, testers, and a few power users got very detailed error messages, ordinary users got friendly, simplified messages (and weren't told about the environment variable).
I found this article interesting but lacking. Lightning also sometimes travels from the ground up to the clouds. Storm clouds produce red sprites (there are some theories about these) and blue jets, that shoot upwards towards space. Then there's ball lightning. None of these phenomena were discussed in the article.
I don't think scientists fully understand lightning at all. (At least, I don't!)
The thing is, I don't need that training to recognize that they are failing to contribute to society.
An old lawyer joke: What do you call 100 lawyers drowning in the ocean? A good start!
(Told to me by my dad, a former attorney till he retired.)
Or more simply, use
su -c 'echo 3 > /proc/sys/vm/drop_caches'Interestingly, the IETF has several published RFCs for text protocols, all of which require \r\n line endings.
<https://www.rfc-editor.org/old/EOLstory.txt>
Note this does not apply to file formats (except for RFCs).
In general, I find it unacceptable for programs to use (anywhere in) my file system, besides /tmp, as a dumping ground for their caches and downloads, without cleaning it up.
/tmp must be world-writable and for multi-user or multi-tenant systems it becomes a security hole. Storing temporary files in the current user's home directory (or a subdirectory thereof) makes sense.
What doesn't make sense is this blog post about TMP and TEMP, and ending with "I don't know why" (in different words).
The reason is simple: different programmers thought the other name was bad. They were under no obligation to come to a consensus.
Don't forget about TEMPDIR and TMPDIR! Also Windows has its own environment variables for this. But generally, Linux software ported to Windows still use TMP or TEMP.
I was thinking of DEL, but was obviously mistaken. Thanks for catching that!
Thomas Jefferson famously said that "A coreutils rewrite every now and again is a good thing". Or something like that.
When I was a beta tester for System Vr2 Unix, I collected as many bug reports as possible from Usenet (I used the name "the shell answer man". Looking back I conclude that arrogance is generally inversely proportional to age) and sent a patch for each one I could verify. Something like 100 patches.
So if this rust rewrite cleans up some issues, it's a good thing.
... Unicode says that 0xFF is an invalid character.
Not so. You may be thinking of UTF-8 encoding. 0xff is DEL in Unicode.
My mental model of columnar storage is as the old notion of parallel arrays, which I used in the 1970s with FORTRAN. Whatever you learned first sticks with you and you end up translating everything to that, or at least I do. I believe this is known as the baby duck syndrome.
The source and destination addresses don't change. If a bomb takes out a router in-between (the military scenario DARPA had in mind), it is NOT IP (L3) or TCP (L4) that handles it. Rather it is a dynamic routing protocol that informs all affected routers of the changed route. Since the early days of the Internet, that's been the job of routing protocols.
For smaller internets, protocols such as RIP (limited to 16 hops) broadcast routing information from each still-working router to other routers. Each router built a picture of the internet (simplifying a bit here, RIP and similar protocols used "distance vector" routing, but other more advanced routing protocols did have each a picture of the internet). So when a packet arrived at its router, that router can forward the pack towards the destination. Such protocols are "interior" routing protocols, used within an ISP's network.
The Internet is too big for such automatic routing and uses an "exterior" routing protocol called BGP. This protocol routes packets from one ISP to the next, using route and connectivity information input by humans. (Again I'm simplifying a bit.)
Wifi uses entirely different protocols to route packets between cells.
Fun fact: wifi is not an acronym for anything, the inventors simply liked how it sounded.