HNHacker News
TopNewBestAskShowJobs

Hello71

1,909 karma · joined September 24, 2012

submissionscomments
Hello71··on Inherit environment variables from PID 1 by reading /proc/1/environ
afaik the linux kernel doesn't read environment variables, but it does write some: processes spawned by the kernel, such as init, modprobe, and request_key, start with some pre-defined environment variables, like HOME=/ TERM=linux PATH=/sbin:/usr/sbin:/bin:/usr/bin.
Hello71··on Ask HN: Why is the Wikipedia Foundation's begging tolerated?
what percentage of the money actually goes to the volunteers?
Hello71··on Btrfs in Linux 6.2 brings performance improvements, better RAID 5/6 reliability
according to https://arstechnica.com/gadgets/2021/09/examining-btrfs-linu..., btrfs devs say you should not add degraded to fstab, and doing so can easily result in data loss.
Hello71··on Termux on Android 5 or 6
termux doesn't use most of the system libraries that are likely to be remotely exploitable, e.g. openssl and webview. the remaining unupdatable weakness is the kernel, but it's pretty unlikely to have a TCP RCE or something like that. there's SACK Panic, but that's only DoS, not RCE, and if you're running something on android 5 you probably have low reliability expectations anyways.
Hello71··on Replacing forks and chopsticks with pincers
after reading a reddit thread a few months ago about why forks are better than chopsticks, I realized that food and the utensils used to eat it are actually highly culturally intertwined.

for example, a key argument in favor of forks was that fork and knife is vastly superior to chopstick and knife when eating steak. Asian cultures simply don't have this issue, because they don't eat steak, because they don't (historically) have huge pastures for free cattle grazing. in Asian cuisine, meat is served pre-cut, not in large chunks for the diner to cut themselves. therefore, Asians don't have the problem of cutting steak at the table.

similarly, Americans rarely eat soft tofu; although tofu is gaining popularity in the US, mainstream grocery stores and restaurants selling tofu tend to sell firm tofu, probably mainly because it's closer to meat in texture. firm tofu is usually served pre-cut, for various reasons including that firm tofu is usually served with stronger and more uniform flavoring. therefore, Americans don't need to cut their soft tofu at the table.

chopsticks are also useful for taking individual bites out of a shared plate without disturbing the remaining contents. consider taking one bite of a shared salad using a fork: it's impossible to do so without either slightly crushing the remainder of the salad, which is impolite, or using the fork as a spoon, which is highly inefficient (salad falls off easily). Americans don't have this problem because they generally take a large portion of salad using a spoon or tongs, then use the fork to take bites from their own plate where it's acceptable to slightly crush the salad.

Hello71··on Replacing forks and chopsticks with pincers
despite Chinese-American fast food restaurants typically using cheap disposable bamboo chopsticks, metal chopsticks also exist and are used in many restaurants. higher-end restaurants typically use high-quality (heavy) polymer or coated wooden chopsticks which can be thoroughly cleaned in regular dishwashers.

edit to add: I enjoy Chinese-American fast food, but like all fast food, it is designed to be cheap, not luxury. it would be like going to an American-style fast food restaurant and complaining that all American food is bad because it gets your hands dirty when eating, or complaining that the cheap disposable plastic utensils are hard to clean (which gets to another point that disposable wooden chopsticks are probably much better for the environment than disposable plastic forks/knives, but that's a digression from a digression)

Hello71··on Does SharePoint destroy intranet design? (2010)
OneDrive for Business is also SharePoint, and Teams is also Exchange (sort of)
Hello71··on The Wonderfully Terrible World of C and C++ Text Encoding APIs (With Some Rust)
you only need 30 MB if you use the ridiculously bloated icu library. musl implements POSIX locale APIs including iconv and wcwidth plus the entire rest of the libc in around half a megabyte. if you need case folding, character classes, or other special functionality, utf8proc is about 0.3 MB, and libunistring is about 1.5 MB.

additionally, if your device has less than a few megabytes of storage, you'll almost certainly be using static linking, which automatically prunes unused code from properly designed libraries.

Hello71··on How criminals are using jammers, deauthers to disrupt WiFi security cameras
https://en.wikipedia.org/wiki/List_of_common_misconceptions#...:

> Microwave ovens are not tuned to any specific resonance frequency for water molecules in the food, but rather produce a broad spectrum of frequencies, cooking food via dielectric heating of polar molecules, including water. Several absorption peaks for water lie within the microwave range, and while it is true that these peaks are caused by quantization of molecular energy levels corresponding to a single frequency, water absorbs radiation across the entire microwave spectrum.

Hello71··on Public buses across country adding microphones to record conversations (2012)
according to that article, the train and station already had surveillance cameras. the current post and comment thread are about surveillance microphones; how would that help with the investigation in your article, where we can reasonably assume that the robbers were shouting things like "open your bag" and "give me your wallet", and interview witnesses to confirm our assumption?
Hello71··on Win32 Is the Only Stable ABI on Linux?
> Wine isn't set up to support multiple installed versions of itself.

huh? the official wine packages for ubuntu, debian, and i believe fedora provide separate wine-devel and wine-staging packages, which can be installed in parallel with each other and with distro packages. in fact, debian (and ubuntu) as well as arch provide separate wine and wine-staging packages as part of the distro itself, no separate repo required.

wine has no special support for relocated installations, but no more or less so than any large Unix program; you can install as many copies as you want, but they must be compiled with different --prefixes, and you cannot use different versions of wine simultaneously with the same WINEPREFIX.

Hello71··on Win32 Is the Only Stable ABI on Linux?
that's running it directly on musl. gcompat is more like a passive adapter which works except you need to know if the device you're plugging in actually supports 240V, which most stuff does nowadays but when it doesn't it explodes horribly.
Hello71··on Win32 Is the Only Stable ABI on Linux?
with difficulty, and not that well. for example, firefox binaries require gtk built with support for X, despite only actually using wayland at runtime if configured. the reason why people generally don't complain about it is because if you have this sort of weird configuration, you can usually compile firefox yourself, or have it compiled by your distro. with binary-only releases, all complaints (IMO justifiably) go to the proprietary software vendors.
Hello71··on How Discord supercharges network disks for extreme low latency
while i am not a "cloud expert", i'm pretty sure that google datacenters have more than one switch. furthermore, while the precise datacenter layout is probably secret, i infer that the the compute servers and the data servers cannot be housed in the same or nearby racks, since both are independently provisionable and can be arbitrarily attached. for example, if i start a vm and connect a drive, even if google could put them right next to each other in the datacenter, what happens if i start another vm, which for fragmentation reasons gets placed way on the other side of the building, detach the drive and connect it to this new one?

therefore, there must at least be several switches between the devices, and realistically, probably one or more routers.

Hello71··on Killbutmakeitlooklikeanaccident.sh
not if the program is statically linked and stripped.
Hello71··on Development Environments
This reminds me of when people say that the Visual Studio debugger is much better than gdb, or that Windows developer tooling in general is better than Linux tooling.

I believe the main reason why gdb kinda stinks is that it can be: traditional Unix-like operating systems typically have smaller components with well-defined interfaces, making them much easier to debug. Windows has too many DLLs, too many interfaces between them, and poor definition of layers. Quick, what's the difference between kernel32 and kernelbase? How do I tell which one a program is using?

This is not to say that Unix-like systems have perfect interfaces, merely that they're generally better-factored than interfaces inside Windows and Windows applications. Further comments can be made of the differences between Windows and Mac "applications" and Linux "programs": for example, the difference is not only in GUI or TUI or CLI: Firefox is an "application", but Notepad and Calculator are "programs"; Paint is a "program", but Paint 3D is an "application".

Hello71··on Development Environments
i was able to find the xxhash core within 5 minutes, with no particular experience in xxhash or hashing algorithms.

1. google xxhash, click first result (github)

2. open xxhash.c

3. see it is mostly empty, go back and open xxhash.h. this file is 6k lines (not 20k), it probably has most or all of the implementation somewhere.

4. starting from top of file, read intro docs: "xxHash [...] is proposed in four flavors, in three families: 1. @ref XXH32_family: Classic 32-bit hash function." i will select XXH32 for illustration.

5. scroll down to examples, which calls "return XXH32(string, length, seed);"

6. ctrl-f "XXH32(", could be done in any text editor (even notepad)

7. press enter 6 times

8. see "@brief The implementation for @ref XXH32().", we have probably arrived at the core or reasonably close to it. if that didn't work, then I would try "XXH32 (", which would immediately find the XXH32 function.

of the 6k lines, about 550 are empty, about 2800 are comments, and about 800 are preprocessor directives. the comments appear to be mostly useful comments, not the "/* Frobnicate the bar. */ int Bar::frobnicate()" type which tend to be seen in IDE-overuse projects.

Hello71··on What a gas stove ban means for restaurants
that's true, I didn't think about that. a restaurant probably has better ventilation and better fuel than a crappy household wood stove, but even, say, half a pack per day is a lot.
Hello71··on What a gas stove ban means for restaurants
biofuel is carbon-neutral. it might cause some particulate pollution, but if it's minimal enough for use in a restaurant dining area, then the environmental impact is probably negligible.
Hello71··on Ffmpeg Buddy
Selecting both scale and rotate options results in:

  Multiple -filter, -af or -vf options specified for stream 0, only the last option '-filter:v transpose=1' will be used.
-vn, -an, -ss, and -to are specified as output rather than input options, which are much more efficient.
Hello71··on System Font Stack
this only looks terrible because you've forced a specific height in rem. https://jsfiddle.net/vbd3fok5/ looks fine to me. there is some extra space, but I assume that if the font designer added extra space on top of the text, they did it on purpose. if you insist on ignoring that, https://jsfiddle.net/qpb0d45n/ makes the text "visually continuous", at least for a non-Korean reader like myself. I would speculate that a Korean user might look at this and ask why the site designer ignored their font's preference for space above the text.
Hello71··on Bing contract prohibits DuckDuckGo from completely blocking Microsoft tracking
and what is the rut=4a9ada2347e29c8fce96a95bde34e6343c279202dbc22b4fe61524ab39bf8eff for?
Hello71··on Town Seized Building, Offered to Return It If Owners Bought Two Cars for Police
> It was almost impossible to prosecute a ship owner who lived across the ocean in Europe, so simply seizing a ship and its smuggled goods was a viable alternative.

why not? prosecute them normally, if they show up then the trial proceeds as usual, if not then convict them in absentia and then forfeit the goods. why does this require a whole new system that bypasses all the constitutional rights for domestic citizens?

Hello71··on No, you can’t save £30 per year by switching off your “standby” devices
My ASRock B450 Pro4 draws about 3W from the wall if WOL is enabled, which in ASRock's firmware seems to keep all PCI devices (and attached USB devices) powered. 30W seems impossible though, anything not specifically designed to be fanless will almost certainly need to turn on the fan at that power usage (and even fanless might have difficulty dissipating a constant 30W).
Hello71··on Japan's Hometown Tax (2018)
is it common to need to take the FTC on residence taxes? my understanding is that US federal income taxes are lower than most foreign taxes, and skimming the Japanese personal income tax brackets, it seems to be slightly higher than US federal income taxes (ignoring deductions).
Hello71··on Web color is still broken
setting aside whether a gif is really necessary, it was surprising to me that your gif is so large, considering it's mostly flat colors, albeit at a fairly high frame rate. running it through gifsicle -O3 takes off 1 MB, and -O3 --lossy takes off another MB. -O3 --colors 4 drops it by another 2 MB, for a total of 69% file size reduction, at the cost of some minor fringing only visible when displayed full-screen.
Hello71··on Changing std:sort at Google’s scale and beyond
while i agree with you to some extent, i don't think including a very large set of sorting functions in the standard library is a good idea. especially for dynamic languages, a larger standard library means more disk usage and worse cache utilization. it's also typically relatively easy to use your own sort function: in performance-critical cases, the sort function is usually called directly, not via intermediate libraries (which might need to be patched to call the new sort function); also, sort functions are self-contained, i.e. typically don't require system dependencies.
Hello71··on Debian and firmware
the generous interpretation of their comment is that their loyalty is predicated on an understanding of shared values; if it transpires that the values are not, in fact, shared, then their relationship may require re-evaluation.
Hello71··on The Colorado Safety Stop is the law of the land
Your avoidance of the issue is almost impressive. You should run for president! First you aggressively claim "maybe a lawsuit against the cyclist for damages, if I want to be an asshole. Because the cyclist was in the wrong."; now you claim that "I’m saying that right of way is the least concern". Forgive my skepticism that I am the one that wants cyclists to be killed.
Hello71··on The Colorado Safety Stop is the law of the land
Firstly, googling "cycling 20 mph", the first result is "20mph is a speed most cyclists are not able to average."

Setting that aside, this is the exact purpose of speed limits, not one-way streets. One-way streets do not prevent pedestrians from popping out behind "bends, turns, hills/humps, or other obstructions", or children, or debris, or potholes, or stopped or malfunctioning cars, or construction, or sudden road ends...

Edit: If you can't stop in time for a bicycle, you can't stop in time for anything, and you need to drive slower. Unfortunately, many American drivers seem to believe that they own the road, and if dumb children run out onto the road and get flattened, that's their own fault for breaking the law.

← PreviousPage 3 of 33Next →