]> git.pond.sub.org Git - empserver/blobdiff - src/lib/commands/fort.c
Update copyright notice
[empserver] / src / lib / commands / fort.c
index 732f15bc404ca02d2a8b16d2f38ee757b14b3c74..f42843fa92a3b1627a0b7f517c0dc2d3de22988d 100644 (file)
@@ -1,6 +1,6 @@
 /*
  *  Empire - A multi-player, client/server Internet based war game.
- *  Copyright (C) 1986-2006, Dave Pare, Jeff Bailey, Thomas Ruschak,
+ *  Copyright (C) 1986-2008, Dave Pare, Jeff Bailey, Thomas Ruschak,
  *                           Ken Stevens, Steve McClure
  *
  *  This program is free software; you can redistribute it and/or modify
 
 #include <config.h>
 
-#include "misc.h"
-#include "player.h"
-#include "land.h"
-#include "nsc.h"
-#include "file.h"
 #include "commands.h"
+#include "land.h"
 #include "optlist.h"
 
 int
@@ -48,8 +44,8 @@ fort(void)
     struct nstr_item ni;
     struct lndstr land;
     int fort_amt, hard_amt;
-    s_char *p;
-    s_char buf[1024];
+    char *p;
+    char buf[1024];
 
     if (!snxtitem(&ni, EF_LAND, player->argp[1]))
        return RET_SYN;
@@ -82,9 +78,9 @@ fort(void)
           use all mobility down to leaving 67 left. */
        if (hard_amt < 0) {
            hard_amt = land.lnd_mobil + hard_amt;
-           if (hard_amt < 0)
-               continue;
        }
+       if (hard_amt <= 0)
+           continue;
 
        if (lnd_fortify (&land, hard_amt) <= 0) {
            pr("%s can't be fortified%s\n", prland(&land),