pooka
71604335b9
add one i saw on irc today
2010-11-25 13:51:26 +00:00
dholland
85288e8bd5
Avoid undefined behavior, from Chris Spiegel in PR 43860.
2010-09-26 21:12:23 +00:00
dholland
388218390b
Rework the game startup so it uses curses nicely. There are now menus
...
and stuff for picking scenarios and ships and all that.
2010-08-06 09:14:40 +00:00
dholland
66d93095d6
Don't define esc-[ as a custom key sequence because it steps on vt
...
function keys.
2010-08-06 03:10:26 +00:00
dholland
f4fdd2aad7
Fix some additional typos/grammar slips.
2010-05-29 22:56:01 +00:00
dholland
c30de92f88
Fix dog-Latin. The plural of wumpus could be wumpi, wumpus, or even wumpora,
...
but not 'wumpii'. Where does this -ii crap come from?
2010-05-29 22:53:49 +00:00
joerg
6394298f1b
Follow the Fundamental Theory of Algebra. Disallow factorising of
...
numbers less than 2 as it is not
- naturally unique (negative numbers)
- finite (0)
- non-empty (1)
Discussed with the kristaps and wiz
2010-05-15 21:22:39 +00:00
joerg
f0352d672f
\\ -> \e
2010-05-14 19:02:28 +00:00
tnozaki
50eb6aadde
cast isblank(3)'s argument to unsigned char.
2010-05-13 17:52:11 +00:00
drochner
d184555b35
rename pollard_pminus1->pollard_rho for consistency
2010-04-28 18:04:31 +00:00
drochner
fe64100e9e
-Fix an old bug in the "pollard" code: it gets its argument passed
...
by reference, and changes the value behind the pointer under some
circumstances (basically if it finds more than 2 different factors).
It also calls itself if it finds a factor which is not considered prime
(by openssl's miller-rabin check) and uses the call argument afterwards.
This doesn't work -- we need to copy the argument into its own storage.
-Modify the code to do the "rho" algorithm as was initially announced.
It takes somewhat longer in rare cases, but still works in cases where
the "p-1" algorithm is unusable. This might fix PR misc/43192
by Luiz Henrique de Figueiredo.
-Add some optional debug support, minor cleanup.
2010-04-27 18:11:19 +00:00
dholland
6763d40772
Document the options that actually exist, instead of some other
...
completely unrelated set. Bump date. (first time since 1993!)
2010-04-24 01:13:37 +00:00
dholland
de82ffd7cb
Handle the "diedtime" field of the player log (which is not the high
...
scores file, the append-only log of all games) as int32_t instead of
time_t. Log files from before the 64-bit time_t change can now be read
again; however, log files from the last year of -current are hosed.
All none of you who play larn, take note...
2010-04-24 00:56:14 +00:00
dholland
b8a40a1a76
fflush the score file while signals are blocked to decrease the chance of
...
it getting corrupted.
2010-04-24 00:38:30 +00:00
drochner
f79e06d729
fix an obvious flaw in bounds check: the array of precomputed primes
...
could be overrun if its last entry (65537) was a factor of the input
(this does not affect PR misc/43192 -- the factors are much larger
here: 7742394596501*159455563099482401)
2010-04-22 14:28:48 +00:00
wiz
0b27f753a1
Add backslash before a dash to get a minus.
2010-04-22 06:57:13 +00:00
dholland
9f8746b55e
Sync with reality. Bump date.
2010-04-22 04:42:21 +00:00
christos
3dc82e5062
handle ctime returning NULL.
2010-04-04 00:08:49 +00:00
christos
99b1f1b15a
ctime can return NULL.
2010-04-02 21:40:00 +00:00
christos
ff4e4fcdee
fix typo.
2010-04-02 19:34:44 +00:00
christos
84ea502702
handle ctime returning NULL.
2010-04-02 15:34:16 +00:00
dholland
5cea3c1fc6
remove #ifdef SVR4
2010-03-29 05:16:08 +00:00
dholland
b7b2c88aa1
Some improvements to the new UI.
2010-03-29 04:28:47 +00:00
dholland
96bcb2af91
reorg for clarity and exposition.
2010-03-29 04:00:03 +00:00
dholland
4a11aa7558
Better user interface. From OpenBSD, written by Paul Janzen quite a
...
long time ago. A few minor adjustments by yours truly.
2010-03-29 03:51:55 +00:00
dholland
3fa2c4cfe9
Spell "versus" right.
2010-03-29 02:48:17 +00:00
dholland
f6d2af84fc
Allow saved game filenames up to PATH_MAX. From OpenBSD.
2010-03-29 02:46:05 +00:00
dholland
fb89b74a21
fix quote markup, spotted in openbsd diffs
2010-03-29 02:34:50 +00:00
dholland
47514c94ae
Fix typo. From OpenBSD.
2010-03-29 02:32:45 +00:00
dholland
bb74336220
Don't exit(0) on failure. Use errx() instead of fprintf.
2010-03-29 02:21:04 +00:00
mrg
5f0f7c9f12
rename text() to wrtext(), aligning it with most other output routines,
...
and avoiding a compile error on powerpc64.
XXX: this tries to make a ".text" symbol, which already exists...
2010-03-22 05:10:19 +00:00
dholland
4db9f70f12
Latin police: use proper conjugation.
...
(whether the rest of the affected fortune is valid either is debatable)
2010-02-16 09:53:51 +00:00
he
76d4444c78
When using -lcurses, you also need -lterminfo.
...
This fixes the build for sun2, and also builds with LDSTATIC=-static,
since archive libraries don't record inter-library dependencies.
2010-02-06 23:45:24 +00:00
roy
98eb889579
Userland now builds and uses terminfo instead of termcap.
...
OK: core@, jdc@
2010-02-03 15:34:37 +00:00
wiz
4c5d0b1878
Close file when finished with it. Found by cppcheck.
2010-01-17 22:56:32 +00:00
wiz
32b30fe688
Simplify alloc() to avoid ifdef(LINT) workaround.
2010-01-17 22:55:20 +00:00
wiz
8c6dae0be9
Close two file descriptors after using them. Found by cppcheck.
2010-01-17 22:52:00 +00:00
mbalmer
5214aa9799
The default output file extension is '.dat', not '.out'.
...
From Lars Nooden via OpenBSD.
2010-01-17 13:35:00 +00:00
joerg
642cfb40e9
Use .%U instead of .%O for URLs.
2010-01-15 19:39:10 +00:00
dholland
2ea1f2138b
Christos points out that usage should not use errx, but should use
...
getprogname.
2010-01-03 17:08:45 +00:00
wiz
4f6260c6a1
New sentence, new line.
2010-01-01 11:45:34 +00:00
dholland
da0f6356ae
Adjust SYNOPSIS for cfscores to better match reality. Note in BUGS
...
that the score file isn't portable. Bump date (first time since 1993,
and first in 2010...)
2010-01-01 07:35:09 +00:00
dholland
381a1804f4
Split struct betinfo into its own header file so it can be shared
...
between canfield and cfscores, instead of copy-pasted.
2010-01-01 06:37:15 +00:00
dholland
97ebabce84
Use NULL instead of 0 for pointer tests. Remove an unnecessary cast.
2010-01-01 06:31:18 +00:00
dholland
93abe19853
Send error messages to stderr. Use errx/warnx, not printf.
2010-01-01 06:20:45 +00:00
dholland
07673b8c8a
Correct usage message.
2010-01-01 06:16:36 +00:00
dholland
f74d700f40
Fix math notation, from PR 41547. While here, fix some potential tab
...
damage in the same fortune.
2010-01-01 00:16:54 +00:00
ahoka
07b3322423
Hide the cursor during the game.
2009-12-19 19:27:53 +00:00
matt
e7e033198e
Fix bad merge. (SUBDIR= != SUBDIR +=)
2009-12-14 20:47:23 +00:00
uebayasi
3a48f7cfa9
Conditionalize some build directories by ${MKCXX}.
2009-12-14 12:43:48 +00:00