summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2021-04-25rio: avoid re-triggering clicks on resize/hide/unhide and send wctl when ↵cinap_lenrek
focus is lost
2021-04-25resample: improve performance (thanks José Miguel Sánchez García)cinap_lenrek
Resample is well known for taking a long time to resize an image. This patch brings an important performance boost (in my test image, time was reduced from ~2850ms to ~500ms). It does that by extracting FP multiplication and division out of the innermost loop of resamplex/resampley. The results differ slightly from the current implementation: in my test: ~0.3% of the bytes had a ±2 difference in their value, which I attribute to rounding errors. I'm personally not concerned with that deviation, given the performance gains. However, I recommend testing it just to be sure I didn't overlook anything. José Miguel Sánchez García
2021-04-24libtags, zuke: add *.mod support (thanks kemal)Sigrid
2021-04-23zuke: fix middle-click restarting playback if held while mouse pointer is movingSigrid
2021-04-22zuke: fix position formatter using a wrong typeSigrid
2021-04-21mergecinap_lenrek
2021-04-21vgadb: revert previous commit, the pci device id 8086/1c3a is the embedded ↵cinap_lenrek
controller!
2021-04-21plumber: fix substrings in match rulesHumm
Unmatched substrings are nil, so we can't rely on nil terminating the array of substrings.
2021-04-20nusbrc: rndis with csp 0104efSigrid
2021-04-20nusb/ether: rndis: add standard class code (tested by jmi2k with OnePlus 8)Sigrid
2021-04-20file: recognize executable scripts, etc.kemal
The patch does the following: 1. Adds recognition of executable script (shebang) files. 2. Returns correct MIME type for mbox files (RFC 4155). 3. Returns XML instead of HTML type in some cases.
2021-04-18devloopback: fix wrong device character (thanks romano)cinap_lenrek
devloopback was changed from using #X to #λ awhile ago; one bit was missed.
2021-04-17patch for imap when imap failsunobe
changeset: 8411:19f6a88ea241 branch: mbp-2011 user: Romano <unobe@cpan.org> date: Sat Apr 17 14:35:21 2021 -0700 files: sys/src/cmd/upas/fs/imap.c description: When an imap fetch fails, it's helpful at times to know the underlying cause. This provides more details by providing the underlying error message.
2021-04-17Mail: remove impliicit headers (thanks unobe)Ori Bernstein
Setting headers from Mail can cause conflicts with the headers that upas/marshal adds when sending attachments. So, let's not set them.
2021-04-14acme: fix border size, autoindent undo: imported from plan9port (thanks jxy)Ori Bernstein
origin: https://github.com/9fans/plan9port/pull/493 https://github.com/9fans/plan9port/pull/489 https://github.com/9fans/plan9port/pull/461
2021-04-13zuke: include libtags in CFLAGSSigrid
2021-04-13zuke: remove -G option (old playlists not supported anymore)Sigrid
2021-04-13remove juke (use play or zuke instead)Sigrid
2021-04-13audio/: zuke, mkplist, readtagsSigrid
2021-04-13remove old, broken scripts: fedex, u(s)ps, weather (thanks fulton)Sigrid
2021-04-12Mail: correctly track the number of messages (thanks igor)Ori Bernstein
We forgot to update the message count when deleting messages in mail, meaning we could access trailing messages that had been freed.
2021-04-12crop: allow no-ops for pipelinesqwx
unlike other tools like iconv(1), a crop(1) without arguments or with ones resulting in a no-op, like `-t 0 0', errors out. other options like `-i 0' do not error. this breaks assumptions and results in tedious intermediary steps or hacks like: foo | {crop -t $1 $2 >[2]/null || cat} > baz.bit instead, just ignore the check. subsequent code doesn't make assumptions on that.
2021-04-11ip/tftpd: add a syslog message about what error we return to the client on a NAKcinap_lenrek
2021-04-11ip/dhcpd: work around raspberry pi pxe firmware by providing dhcp option 66cinap_lenrek
The raspberry pi 4 PXE firmware insists on finding the tftp server address by parsing dhcp option 66 as an ip address string.
2021-04-11ip/ipconfig: ODtftpserver (dhcp option 66) is of type stringcinap_lenrek
2021-04-10termrc, cpurc: silence /net/ether* error message when there are no ethernet ↵cinap_lenrek
devices
2021-04-09libthread: generate correct acid filesHumm
/sys/src/cmd/mksyslib uses `{basename $stem .$objtype}^.c to get the source file name for *.acid files. /sys/lib/acid/thread expects sched.$objtype.acid. This lets /sys/src/libthread/mkfile generate that file.
2021-04-09page: fix for kerTeX dviHumm
2021-04-09disk/fdisk: add OpenBSD partition typeHumm
2021-04-09printfont: load all fonts for `printfont all`Humm
2021-04-09trofftable.rc: make workHumm
2021-04-09g: add lua, mk, ml, mli, myr, and sh suffixeskvik
2021-04-08nusbrc: ignore rndis ethernet in /rc/bin/nusbed, handled by ↵cinap_lenrek
/sys/src/9/boot/nusbrc (thanks romano)
2021-04-08minor man page typosRomano
2021-04-07vgadb: igfx: add vid/did for early 2011 apple mbp (thanks Romano)Sigrid
2021-04-06[9front] walk: properly format permissionsStephen Gregoratto
This patch adds dirmodefmt from fcall.h to pretty-print file permissions, similarly to ls -l. I didn't notice any performance degradation. I hope no-one relied on the old behaviour.
2021-04-03file: detect webp files (thanks kemal)cinap_lenrek
this patch adds a small check to the "iff" function, so this way file can detect webp files. tested with a webp file i found randomly.
2021-04-02games/glendy: your complication had a complication (god damn it kemal)cinap_lenrek
2021-04-02games/glendy: don't use lucida sans in menus by default and bugfix (thanks ↵cinap_lenrek
kemal) i have found one bug. when i put glenda in a position like this i somehow win, but the glenda can escape from there. in addition, i have changed the games manpage to include more info about glendy.
2021-04-02kernel: get rid of physical page bank array and use conf.mem[] insteadcinap_lenrek
We can take advantage of the fact that xinit() allocates kernel memory from conf.mem[] banks always at the beginning of a bank, so the separate palloc.mem[] array can be eleminated as we can calculate the amount of non-kernel memory like: upages = cm->npage - (PGROUND(cm->klimit - cm->kbase)/BY2PG) for the number of reserved kernel pages, we provide the new function: ulong nkpages(Confmem*) This eleminates the error case of running out of slots in the array and avoids wasting memory in ports that have simple memory configurations (compared to pc/pc64).
2021-04-02whois: suppress missing file errors (thanks kivik)cinap_lenrek
2021-04-02acme: fix suicide *and* resource leak in ecmd.c (thanks igor)cinap_lenrek
To reproduce the suicide try running the following in acme: • 'Edit B <ls lib' by select and middle clicking in a window that is in your $home. There is a very high chance acme will commit suicide like this: <snip> cpu% broke echo kill>/proc/333310/ctl # acme cpu% acid 333310 /proc/333310/text:amd64 plan 9 executable /sys/lib/acid/port /sys/lib/acid/amd64 acid: lstk() edittext(nr=0x31,q=0x0,r=0x45aa10)+0x8 /sys/src/cmd/acme/ecmd.c:135 xfidwrite(x=0x461230)+0x28a /sys/src/cmd/acme/xfid.c:479 w=0x0 qid=0x5 fc=0x461390 t=0x1 nr=0x100000031 r=0x45aa10 eval=0x3100000000 a=0x405621 nb=0x500000001 err=0x419310 q0=0x100000000 tq0=0x80 tq1=0x8000000000 buf=0x41e8d800000000 xfidctl(arg=0x461230)+0x35 /sys/src/cmd/acme/xfid.c:52 x=0x461230 launcheramd64(arg=0x461230,f=0x22357e)+0x10 /sys/src/libthread/amd64.c:11 0xfefefefefefefefe ?file?:0 </snap> The suicide issue is caused by the following chain of events: • /sys/src/cmd/acme/ecmd.c:/^edittext is called at /sys/src/cmd/acme/xfid.c:479 passing nil as its first parameter: <snip> ... case QWeditout: r = fullrunewrite(x, &nr); if(w) err = edittext(w, w->wrselrange.q1, r, nr); else err = edittext(nil, 0, r, nr); ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ... </snap> ...and /sys/src/cmd/acme/ecmd.c:/^edittext dereferences the first parameter that is *nil* at the first statement: <snip> char* edittext(Window *w, int q, Rune *r, int nr) { File *f; f = w->body.file; ^^^^^^^^^^^^^^^^^^^^^ This will crash if 'w' is *nil* switch(editing){ ... </snap> Moving the the derefernce of 'w' into the case where it is needed (see above patch) fixes the suicude. The memory leak is fixed in /sys/src/cmd/acme/ecmd.c:/^filelist. The current implementation of filelist(...) breaks its contract with its caller, thereby leading to a memory leak in /sys/src/cmd/acme/ecmd.c:/^B_cmd and /sys/src/cmd/acme/ecmd.c:/^D_cmd. The contract /sys/src/cmd/acme/ecmd.c:/^filelist seems to have with its callers is that in case of success it fills up a 'collection' that callers can then clear with a call to clearcollection(...). The fix above honours this contract and thereby removes the leak. After you apply the patch the following two tests should succeed: • Execute by select and middle click in a Tag: 'Edit B lib/profile' • Execute by select and middle click in a Tag: 'Edit B <ls lib' The former lead to a resource leak that is now fixed. The latter lead to a suicide that is now fixed by moving the statement that dereferences the parameter to the location where it is needed, which is not the path used in the case of 'Edit B <ls'. Cheers, Igor
2021-04-01[9front] [patch] nusb/ether -t rndisRomano
2021-03-31mergecinap_lenrek
2021-03-31devfs: fix locking and ignore undocumented "fsdev:\n" configuration signaturecinap_lenrek
The confstr was shared between readers so seprintconf() could write concurrently to that buffer which is not safe. This replaces the shared static confstr[Maxconf] buffer with a pointer that is initially nil and a buffer that is alloced on demand. The new confstr pointer (and buffer) is now only updated while wlock()ed from the new setconfstr() function. This is now done by mconfig() / mdelctl() just before releasing the wlock. Now, rdconf() will check if confstr has been initialized, and test for it again while wlock()ed; making sure the configuration is read only once. Also, rdconf() used to check for a undocumented "fsdev:\n" string at the beginning of config data tho that was never documented. This changes mconfig() to ignore that particular signature so the example from the manpage will work as documented.
2021-03-29mergeOri Bernstein
2021-03-29libsunrpc: work around arm64 compiler bug in sunStringUnpack()cinap_lenrek
The sunStringUnpack() routine was miscompiled by 7c, as pointer arithmetic is done in 64 bit but the constant -1 offset got expended to a unsigned 32 bit integer.
2021-03-23kbmap/tr: add one missing key to Turkish keymap (thanks kemal)Ori Bernstein
while we're here, change the hex values to unicode chars.
2021-03-23legal: mit neuer lizenz: mitOri Bernstein
The Plan 9 foundation has ownership of the Plan 9 code now, and has made it accessible under the MIT license, so we're taking that version of the code as our base now.
2021-03-13kernel: remove ucalloc.c duplicatescinap_lenrek