- Nov 14, 2015
-
-
Andrew Price authored
Change scripted with coccinelle: @rule0@ expression A,B; @@ - lseek(A, B, 0); + lseek(A, B, SEEK_SET); @rule1@ expression A,B; @@ - lseek(A, B, 1); + lseek(A, B, SEEK_CUR); @rule2@ expression A,B; @@ - lseek(A, B, 2); + lseek(A, B, SEEK_END);
-
Andrew Price authored
-
- Nov 11, 2015
-
-
Andrew Price authored
Also get rid of some unnecessary global variables.
-
- Nov 09, 2015
-
-
Andrew Price authored
-
Andrew Price authored
sed does it better.
-
Andrew Price authored
Half of it relates to MUD mode, the other half is out of date.
-
Andrew Price authored
-
Andrew Price authored
Spotted by scan-build
-
- Nov 08, 2015
-
-
Andrew Price authored
Also make the alias type not-a-pointer to improve readability and allocate all of the memory required for an alias in one go.
-
- Nov 07, 2015
-
-
Andrew Price authored
Makes sure we don't create the directories with root ownership. Also make mwserv's stdout line buffered to work better with logging systems which capture stdout.
-
Andrew Price authored
- Run as mw:mw - Make systemd create and cleanup /var/run/mw for us - Correct the path to mwserv
-
Andrew Price authored
(And less shouty.)
-
Andrew Price authored
Make it static but add a convenience pointer to it to take the place of the previous user pointer. Make the pointer itself const so that the compiler complains if anything besides the original user's address is assigned to it.
-
Andrew Price authored
-
Andrew Price authored
And tidy up command.c a bit
-
Andrew Price authored
Don't start at the beginning of the user db each time.
-
Andrew Price authored
-
Andrew Price authored
-
Andrew Price authored
-
Andrew Price authored
-
Andrew Price authored
-
- Nov 06, 2015
-
-
Andrew Price authored
-
Andrew Price authored
-
Andrew Price authored
-
- Oct 31, 2015
-
-
Andrew Price authored
Huzzah!
-
Andrew Price authored
!folder name was not working because strlen("name") was expected to be 5. Expect it to be 4 instead.
-
Andrew Price authored
This moves the folder index, text, moderation and tmp files into directories corresponding to the file name suffixes currently in use. Old New --- --- STATEDIR/foo.i STATEDIR/index/foo STATEDIR/foo.i.m STATEDIR/index/mod/foo STATEDIR/foo.i.t STATEDIR/index/new/foo STATEDIR/foo.t STATEDIR/text/foo STATEDIR/foo.t.m STATEDIR/text/mod/foo STATEDIR/foo.t.t STATEDIR/text/new/foo This has the following advantages: 1. No more ugly folder path building all over the place 2. STATEDIR and PATHSIZE used in far fewer places 3. No longer assumes paths to folder files will fit in 256 chars 4. A tidier STATEDIR 5. Better separation of concerns (more folder stuff hidden in folders.c) 6. Should make it easier to move the folder stuff into the server 7. Improved error checking/reporting This makes use of the *at family of syscalls so, instead of building paths, we now use file descriptors.
-
- Oct 29, 2015
-
-
Dom Rushbrook authored
-
Dom Rushbrook authored
-
- Oct 24, 2015
-
-
Andrew Price authored
-
- Oct 23, 2015
-
-
Andrew Price authored
An earlier patch accidentally left a zero userposn in ipc_connect but we don't have a userposn now so ipc_connect now accepts a struct user to identify as. This makes reconnecting in ipc_check() a little trickier so pass the stored target in from outside instead of checking for NULL. Also add some error checking.
-
Andrew Price authored
Also switch to pread.
-
Andrew Price authored
-
Andrew Price authored
We're using user->posn now.
-
Andrew Price authored
-
Andrew Price authored
-
Andrew Price authored
-
Andrew Price authored
Wrap the userposn and struct person in a new user structure which can be used to pass around all of the date related to the user, not just the on-disk bits. This should make things easier down the line when replacing the users.bb format with a more flexible one.
-
Andrew Price authored
-
Andrew Price authored
-