Joshua Kwan
6f11c9053a
Regenerate dependencies, function prototypes, remove useless includes, globals,
...
and make code more readable. Move externs into a header file, just tidying up.
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@186 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-30 02:49:29 +00:00
Joshua Kwan
282721fc0b
add a clear() that might be needed in case a process isn't HUPable and we
...
ask the user if he wants to SIGTERM it
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@183 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-30 00:56:46 +00:00
Joshua Kwan
aaaa35c525
Fix some stuff related to HUP'ping processes (not completely fixed yet)
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@181 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-28 16:31:37 +00:00
Joshua Kwan
6e6be8f40c
re-mention virus and last_char_is.c in COPYING
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@179 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-27 17:31:26 +00:00
Joshua Kwan
2c83144f25
Fix bug in populate_games where only first game would be seen (!)
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@178 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-27 09:05:39 +00:00
Joshua Kwan
1547d8cbdc
bail out if you specified a config file, and it's ENOENT - less confusing
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@176 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-26 16:50:13 +00:00
Joshua Kwan
a095001e0a
remove deep_copy function, rename initncurses to initcurses
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@169 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-26 08:29:04 +00:00
Joshua Kwan
0957e52c6c
land final virus+ee support
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@163 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-25 22:44:34 +00:00
Joshua Kwan
c4932ed44b
Cleanups - globals, extraneous #defines, #include order, etc.
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@161 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-25 22:34:35 +00:00
Joshua Kwan
e218bf1055
fix canned rcfile path
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@157 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-23 18:33:35 +00:00
Joshua Kwan
849a8c5012
Throw out virus in favor of ee, which is much more newbie-friendly and somewhat
...
less iffy than virus.
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@150 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-23 18:14:48 +00:00
Joshua Kwan
8ea6b70149
rearrange preprocessor stuff
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@148 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-23 16:40:51 +00:00
Joshua Kwan
410a4f8d96
- no need for strdup, we never free myconfig
...
- use defconfig for default passwd/lockfile
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@145 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-21 16:47:30 +00:00
Jilles Tjoelker
390c2666cd
Give a message when the max number of users has been reached, avoiding the
...
creation of a too large user list.
If the list was not too large when selecting the 'r' option, but is after all
data has been entered, bail out without message and corrupting the
terminal settings (oops).
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@142 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-21 16:31:40 +00:00
Joshua Kwan
8b9c796b10
Add ability to change location of passwd and lockfile.
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@137 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-21 01:57:44 +00:00
Joshua Kwan
7c8eebf836
warning message when config file = ENOENT
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@136 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-21 01:49:40 +00:00
Joshua Kwan
be57b91ba1
Additional anti-root uid security fixes
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@134 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-21 01:37:16 +00:00
Joshua Kwan
0f9d024d26
ncurses.h -> curses.h
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@129 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-19 16:56:03 +00:00
Jilles Tjoelker
2e89c7c3be
Own version of getnstr() that always recognizes ^H and ^?; now always noecho(); mygetnstr() echoes if necessary.
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@128 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-19 11:58:31 +00:00
Jilles Tjoelker
1a081cc170
Solaris compatibility.
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@123 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-16 16:36:33 +00:00
Joshua Kwan
61efafdd49
don't use on BSD and Linux, setenv(3) is BSD 4.3
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@120 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-16 02:02:40 +00:00
Joshua Kwan
ff73c6b2cb
mysetenv() for portability
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@119 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-16 02:00:47 +00:00
Joshua Kwan
2063de2fdc
init a struct flock
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@118 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-16 01:37:33 +00:00
Joshua Kwan
1059fae93b
solaris portability fixes
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@117 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-12 17:32:47 +00:00
Jilles Tjoelker
c2be1a8882
Reset SIGWINCH to default before starting game to prevent that window resizes
...
during play cause disconnects.
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@110 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-06 14:27:56 +00:00
Jilles Tjoelker
7fab8e128d
Some fixes to simplemail. It appears to work for me now.
...
To keep it simple, 'm' quits out of watching.
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@107 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-06 13:35:38 +00:00
Jilles Tjoelker
488c628565
Same snprintf size bug again.
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@105 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-06 13:16:31 +00:00
Jilles Tjoelker
974f567f04
snprintf() size argument was 1 too small, so MAIL variable always missed
...
last char.
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@104 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-06 13:11:07 +00:00
Joshua Kwan
c8739c386b
fix case where argv[1] == ENOENT
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@102 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-06 05:03:30 +00:00
Joshua Kwan
0b590733ff
Here's a better fix
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@100 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-06 02:08:53 +00:00
Joshua Kwan
52e8cb7de8
fix truncation of any banner stuff after appending $VERSION
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@99 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-06 01:57:49 +00:00
Joshua Kwan
ecc8f9b897
this should really be strncmp
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@94 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-05 17:37:21 +00:00
Joshua Kwan
9419e79454
some fixes
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@92 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-05 17:27:49 +00:00
Joshua Kwan
8da9e3acdc
Quick fix
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@84 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-05 01:57:25 +00:00
Joshua Kwan
4f6bec9c0a
It kind of works now. However, we must beware the static buffers that we made
...
before. They might no longer be enough.
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@83 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-05 01:55:08 +00:00
Joshua Kwan
6901a281a0
First try at the config file system. Still need to change usage of all
...
the macros, currently, this has no effect on dgamelaunch's functionality.
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@82 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-05 01:25:38 +00:00
Joshua Kwan
4aed9485f4
reindentation
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@80 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-04 22:49:29 +00:00
Brett Carrington
1adf4dbb69
Stupid pointless TODO: in comment
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@79 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-04 20:16:59 +00:00
Joshua Kwan
5a623c9d44
Fix problem with people entering initial blank password.
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@77 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-04 12:16:05 +00:00
Joshua Kwan
58d70cd5e3
replace two big conditionals with isalnum(3) calls
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@76 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-04 12:07:38 +00:00
Joshua Kwan
ab14b92451
Ok, readd strlcat.c, use strlcat instead of strncat
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@74 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-04 07:35:14 +00:00
Jilles Tjoelker
7ad4523dae
Provide some feedback to the user that he has a stale game.
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@72 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-04 02:56:09 +00:00
Joshua Kwan
c76193877d
fix some typos, add the crew to the copyright blurb
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@71 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-04 02:54:01 +00:00
Joshua Kwan
b0ba0861ea
ok, now it works
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@70 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-04 02:35:40 +00:00
Jilles Tjoelker
acfec7933e
Terminate if user chooses not to kill a hung game, and don't delete lockfile
...
in that case.
Move purge_stale_locks() call to before final endwin() in main().
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@69 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-04 02:31:00 +00:00
Joshua Kwan
f20200f40c
check for . and ..
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@68 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-04 02:28:57 +00:00
Joshua Kwan
e9a719ea90
oops, big bug
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@67 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-04 02:20:54 +00:00
Joshua Kwan
71f367b1b4
Reindent, and add some error handling for kill
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@66 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-04 02:19:12 +00:00
Joshua Kwan
0daf7cdb3b
Move gen_inprogress_lock() call to ttyrec.c, with the pid of nethack, and
...
purge_stale_locks() to remove all stale lockfiles.
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@65 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-04 02:03:26 +00:00
Brett Carrington
45afd54ca0
graceful_exit, does nothing but please deprecate exit().
...
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@63 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
2004-01-04 01:45:21 +00:00