Commit graph

4798 commits

Author SHA1 Message Date
mischief
f785d4da07 aux/statusbar: use title as rio window title (thanks qrstuv) 2015-08-18 01:24:22 -07:00
cinap_lenrek
7c3bbc3168 libsec: TLS1.2 server support, make cipher list with most prefered first 2015-08-17 22:27:56 +02:00
cinap_lenrek
7d7650dffc libsec: TLS1.2 client support 2015-08-17 21:16:58 +02:00
cinap_lenrek
873850c33d bullshit: app, deep-learning, responsive. 2015-08-17 13:11:31 +02:00
cinap_lenrek
70a7ae9929 cc: improve (non-) side effect detection (thanks charle) 2015-08-17 02:07:27 +02:00
cinap_lenrek
dd4c85cf3a games/doom: fix array offsets for respawn angle (thanks qu7uux)
mthing->angle is a signed short, and if ANG45 * mthing->angle/45 < 0, the
result of the right shift is sign extended.
afaik, an being 16bit in the dos version of doom, you'd endup with a
negative array offset, which would just access values from adjacent arrays
(finetangent[] for finecosine[], and finecosine[] for finesine[]), and it
would result in a misplaced teleport fog in some circumstances (fog is not
in front of the player on respawn, hence "silent teleport"). so, this fix is
bug incompatible, but this only affects live multiplay.
to test:
% hget http://doomedsda.us/dm/ahfx7_2.zip | unzip -sv
extracting AHFX7_2.TXT
extracting AHFX7_2.LMP
% mv AHFX7_2.LMP ahfx7_2.lmp
% games/doom -playdemo ahfx7_2
[...]
doom 10553: suicide: sys: trap: fault read addr=0x400429e10 pc=0x205b45
2015-08-16 22:12:11 +02:00
cinap_lenrek
f369fa9d46 games/doom: fix gamma correction and key translation (thanks qu7uux)
KEY_F11 and KEY_F12 are not KEY_F1+11 and KEY_F1+12 as it is assumed in
runetokey(), which prevents these keystrokes from being used. rather than
change runetokey(), it seems better to just change the key definitions in
doomdef.h (the new values don't correspond to any other keys anyway).

F11 is the gamma correction key. to make gamma correction actually work,
i_video.c:I_SetPalette must also take into account usegamma (this was just
never ported). cf i_video.c:UploadNewPalette in source code release.

F12 is the spycam key. the spycam switches the renderview to a different player
during a coop game, or when watching a multiplayer demo. this feature only
changes the renderview; sounds, palette effects, status bar, etc. are still
from the first player's perspective.
2015-08-16 22:09:46 +02:00
cinap_lenrek
f47f6af382 games/doom: fix idclev cheat in doom2 and final doom (thanks qu7uux)
a typo in st_stuff.c:ST_Responder prevents idclev (change level) cheat to work
in doom2 and final doom (gamemode == commercial): episode is set to 0, when
that's invalid, and ST_Responder just returns.
to test, while ingame type idclev, followed by:
. doom1: episode (1-3 or 1-4) then map number (1-9)
. doom2/final doom: map number (1-32)
incidentally, if the last digit typed is 1, the player's weapon will switch to
the fist, because of a different bug (basically kbdproc registering two events
when pressing a key, for 'c' and 'k' case).
2015-08-16 22:08:11 +02:00
cinap_lenrek
0d76dafaa0 games/doom: fix unterminated comment causing sound bugs (from qu7uux)
this bug was introduced in the plan9 port, and since i_sound.c compiles with
no warning, it was never noticed. in effect, the statement between the
unterminated comment and the next is ignored. channelids[] is used in addsfx()
to avoid re-adding certain sounds if they are already playing. one of those is
sfx_sawful, and because of this bug, it is added again each tic during which
the player fires the chainsaw, rather than reset every tic.
compare firing the chainsaw continuously with and without the patch (without
hitting an enemy).
2015-08-16 22:07:12 +02:00
cinap_lenrek
8c3acde2de devether: duplicate flags when copying blocks (thanks erik quanstro) 2015-08-16 20:08:36 +02:00
cinap_lenrek
988d326f32 vc: word align automatics
theres code that assumes one can dereference a char[] buffer on the stack
as a long (ghostscript gxblend.c), so make sure all automatics on the stack
are word aligned. this is not strictrly neccesary, but avoids some
trouble with unportable code.
2015-08-16 19:29:16 +02:00
cinap_lenrek
2fe2ffe813 gs: fix alignment bug in image_render_interpolate() 2015-08-16 18:20:22 +02:00
cinap_lenrek
cf74c80e7b 6l: fix vlong byte order when running on big endian machine (thanks erik quanstro) 2015-08-16 13:41:14 +02:00
mischief
0b48d5fdbf libcontrol: fix label memory leak 2015-08-16 00:04:27 -07:00
cinap_lenrek
f1efd09bbb mothra: fix crash 2015-08-16 03:19:05 +02:00
cinap_lenrek
344ddf5f55 rio(4): document "delete" wctl message (thanks mischief) 2015-08-16 02:54:23 +02:00
cinap_lenrek
aa2b5bc0e7 libsec: fix mistake breaking tlsServer() (thanks sl) 2015-08-16 02:38:44 +02:00
cinap_lenrek
5e07e5840a cpu: cleanup ssl code, make sure -p works for any auth method 2015-08-16 01:47:10 +02:00
cinap_lenrek
e9e53fe7b6 import(4): clarify -E and -e options 2015-08-15 21:36:18 +02:00
cinap_lenrek
0c36c79e9b libsec: TLS1.1 support (needs new devtls) 2015-08-15 17:51:55 +02:00
cinap_lenrek
74d1f67b05 devtls: TLS1.1 explicit iv support
using nrand() to fill the explicit iv, which isnt great but better
than no iv.
2015-08-15 17:50:44 +02:00
cinap_lenrek
76f21ca715 kernel: try freebroken() *before* killbig() (thanks aiju) 2015-08-14 14:45:19 +02:00
cinap_lenrek
592b8d5b35 hjfs: fix deadlocks
buffers which still have requests queued on them are not free!

we cannot chanedev() a buffer while it has still requests queued on it
and we canot just queue our request (having different address) on the
buffer while there are other requests before it, otherwise we would
create artificial block dependency that can cause deadlock.
2015-08-13 10:41:12 +02:00
cinap_lenrek
8c4bb53bdc hjfs: fix abort() in givebuf()
it is possible for another getbuf() on buffer b to come in
before undelayreq() calls givebuf() on a buffer again. then
givebuf() would find b already busy and abort().

instead, we now handle what getbuf() did in givebuf() and
consider the Buf* argument to givebuf() as a hint only for
the case when we have to actually flush/read a block from
disk.
2015-08-11 17:56:06 +02:00
cinap_lenrek
f43df64325 libc: fix wunlock() libthread deadlock
when wunlock() was used by threads running within the same proc,
the wunlock() can deadlock as it keeps holding the RWLock.lock
spinlock while indirectly calling _threadrendezvous(). when
_threadrendezvous() switches to another thread in the same proc,
then that thread can hang at rlock()/wlock()/runlock() again
waiting for wunlock() to release the spinlock which will never
happen as lock() does not schedule threads.

wunlock() is changed to release the spinlock during rendezvous
wakeup of readers. note that this is a bit dangerous as more
readers might queue concurrently now which means that if
we cannot keep up with the wakeups, we might keep on waking
readers forever. that will be another patch for the future.
2015-08-10 23:13:41 +02:00
mischief
bc895417f8 libc: fix spim endianness 2015-08-09 03:44:03 -07:00
cinap_lenrek
23742053f5 mount, srv: add -N flag to skip authentication and attach anonymously as "none" 2015-08-10 10:11:45 +02:00
stanley lieber
b241dd1159 fortunes: If you want to do the work, I will review the results. 2015-08-09 00:36:10 -04:00
cinap_lenrek
4b926f4e69 lib9p: make reqqueueflush() use new threadint(), which will also cover channel operations
using "interrupt" ctl message directly doesnt work when the
process is doing libthread channel operations (threadrendezvous)
as it will just repeat a interrupted rendezvous(). threadint()
handles this for us.
2015-08-10 03:52:40 +02:00
cinap_lenrek
c235046310 libthread: use "interrupt" proc ctl message instead of posting a note for threadint()
threadint() is called to interrupt channel operation or a system call.
the kernel provides a new "interrupt" procctl message to interrupt a
process commited to or being in a blocking syscall, which is similar,
but not the same. the main difference is that "interrupt" condition
is not cleared before the process actually attempts to block. also
can be cleared with "nointerrupt" ctl message. see proc(3)
2015-08-10 03:48:37 +02:00
cinap_lenrek
a98f911a17 libthread: fix mistake, make "all" the default target again 2015-08-10 03:20:08 +02:00
cinap_lenrek
7a97fe132a acid -k: fix intrcount() for amd64 2015-08-09 22:43:53 +02:00
cinap_lenrek
cd357a2b8c acid -k: fix procenv() to new data structure 2015-08-09 22:24:50 +02:00
cinap_lenrek
8c9e4efa17 zunq: remove unused variables from devqspi 2015-08-09 22:05:14 +02:00
cinap_lenrek
7ba3be82a7 kernel: move "setargs" field in Proc structure after "nargs" and "args" 2015-08-09 21:48:58 +02:00
cinap_lenrek
b4f56f1f4e kernel: mount flag is int not ulong, reduce size of Mount struct by putting mflag field in what would be wasted as padding 2015-08-09 21:35:50 +02:00
cinap_lenrek
9f4eac5292 kernel: pgrpcpy(), simplify Mount structure
instead of ordering the source mount list, order the new destination
list which has the advantage that we do not need to wlock the source
namespace, so copying can be done in parallel and we do not need the
copy forward pointer in the Mount structure.

the Mhead back pointer in the Mount strcture was unused, removed.
2015-08-09 21:16:10 +02:00
cinap_lenrek
3af236b5e3 kernel: fix Mheadache
there was a race between cunmount() and walk() on Mhead.from as Mhead.from was
unconditionally freed when we cunmount(), but findmount might have already
returned the Mhead in walk(). we have to ensure that Mhead.from is not freed
before the Mhead itself (now done in putmhead() once the reference count of the
Mhead drops to zero).

the Mhead struct contained two unused locks, removing.

no need to hold Pgrp.ns lock in closegrp() as nobody can get to it (refcount
droped to zero).

avoid cclose() and freemount() while holding Mhead.lock or Pgrp.ns locks as
it might block on a hung up fileserver.

remove the debug prints...

cleanup: use nil for pointers, remove redundant nil checks before putmhead().
2015-08-09 18:19:47 +02:00
cinap_lenrek
eaf42a2c78 rootstub: add spim 2015-08-08 09:20:48 +02:00
cinap_lenrek
c8a7747659 cdproto: add spim 2015-08-08 08:56:08 +02:00
cinap_lenrek
ff6e15ec3a add /spim 2015-08-08 08:38:25 +02:00
cinap_lenrek
1f8e6c916a python: fix build for objtype=$spim 2015-08-08 08:34:16 +02:00
cinap_lenrek
79213052a2 gs: fix build for objtype=spim 2015-08-08 08:31:49 +02:00
cinap_lenrek
acc4d8b8aa libmp: fix build for objtype=spim 2015-08-08 08:25:36 +02:00
cinap_lenrek
4b6506cb57 ape: fix build for objtype=spim 2015-08-08 08:17:54 +02:00
cinap_lenrek
ebe88f34cb fix library mkfiles for objtype=spim 2015-08-08 08:04:41 +02:00
mischief
23215e14d0 libmach: remove redundant check for big endian 2015-08-05 06:37:02 -07:00
mischief
8e78804fc0 libmach: remove useless error check from previous commit 2015-08-05 06:30:57 -07:00
mischief
7844dafe62 libmach: set correct endianness with little endian ELF32 mips binaries 2015-08-05 06:26:23 -07:00
cinap_lenrek
8ce456bd19 kernel: remove unused MAXCRYPT constant from portdat.h 2015-08-06 13:35:03 +02:00