2026-09-29 02:45 UTC
Advanced Programming in the #UNIX Environment
Week 3: recap
Slides from tonight's class, summarizing the last few videos and adding a few more bits (haha, get it?) about how the umask works.
https://stevens.netmeister.org/631/03-f26.pdf
Replies (1)
-
@jschauma@mstdn.social 2026-09-29 22:10
If you create a symlink to a symlink to a symlink ... at some point your system will return ELOOP. A reasonable system has that value defined in sys/param.h as MAXSYMLINKS or as sysconf(_SC_SYMLOOP_MAX). On Linux, the value of MAXSYMLINKS in sys/param.h is 20, but the kernel actually uses 40: https://elixir.bootlin.com/linux/v7.2.8/source/include/linux/namei.h#L14 The sysconf(3) man page on Linux documents _SC_SYMLOOP_MAX, but then fails to actually retrieve that value. Good job, Linux. You illustrate why I use #NetBSD to teach this class.