about summary refs log tree commit diff stats
path: root/src
diff options
context:
space:
mode:
authorThomas E. Dickey <dickey@invisible-island.net>2014-07-24 22:30:44 -0400
committerThomas E. Dickey <dickey@invisible-island.net>2014-07-24 22:30:44 -0400
commitcbe90040d54b4a8855e1b0e4355676816a4e1fd3 (patch)
treee3d6f3c19c1764e5972241ebcba2aa7b39ce2468 /src
parentac88d77df17bca4e43b023e20c8343b2f28f0ea7 (diff)
downloadlynx-snapshots-cbe90040d54b4a8855e1b0e4355676816a4e1fd3.tar.gz
snapshot of project "lynx", label v2-8-9dev_1b
Diffstat (limited to 'src')
-rw-r--r--src/GridText.c4
-rw-r--r--src/LYCgi.c8
-rw-r--r--src/LYCurses.c7
-rw-r--r--src/LYLocal.c5
-rw-r--r--src/LYUtils.c8
-rw-r--r--src/LYUtils.h9
6 files changed, 27 insertions, 14 deletions
diff --git a/src/GridText.c b/src/GridText.c
index f447a5dc..4b52f0c8 100644
--- a/src/GridText.c
+++ b/src/GridText.c
@@ -1,5 +1,5 @@
 /*
- * $LynxId: GridText.c,v 1.277 2014/02/13 19:32:01 tom Exp $
+ * $LynxId: GridText.c,v 1.278 2014/07/24 22:08:24 tom Exp $
  *
  *		Character grid hypertext object
  *		===============================
@@ -14724,7 +14724,7 @@ static int LYHandleCache(const char *arg,
 		   x, STR_LYNXCACHE, x, title, address, address);
 	PUTS(buf);
 	if (Size > 0) {
-	    HTSprintf0(&buf, "Size: %" PRI_off_t "  ", Size);
+	    HTSprintf0(&buf, "Size: %" PRI_off_t "  ", CAST_off_t (Size));
 
 	    PUTS(buf);
 	}
diff --git a/src/LYCgi.c b/src/LYCgi.c
index caa6b6d4..31833eac 100644
--- a/src/LYCgi.c
+++ b/src/LYCgi.c
@@ -1,5 +1,5 @@
 /*
- * $LynxId: LYCgi.c,v 1.67 2013/11/28 11:35:56 tom Exp $
+ * $LynxId: LYCgi.c,v 1.68 2014/07/24 22:02:26 tom Exp $
  *                   Lynx CGI support                              LYCgi.c
  *                   ================
  *
@@ -145,6 +145,10 @@ static int LYLoadCGI(const char *arg,
 		     HTFormat format_out,
 		     HTStream *sink)
 {
+    (void) arg;
+    (void) anAnchor;
+    (void) format_out;
+    (void) sink;
     return -1;
 }
 #else
@@ -510,7 +514,7 @@ static int LYLoadCGI(const char *arg,
 		    status = HT_LOADED;
 		}
 
-#if !HAVE_WAITPID
+#ifndef HAVE_WAITPID
 		while (wait(&wstatus) != pid) ;		/* do nothing */
 #else
 		while (-1 == waitpid(pid, &wstatus, 0)) {	/* wait for child */
diff --git a/src/LYCurses.c b/src/LYCurses.c
index 06ed6017..4608b0a9 100644
--- a/src/LYCurses.c
+++ b/src/LYCurses.c
@@ -1,4 +1,4 @@
-/* $LynxId: LYCurses.c,v 1.179 2014/02/20 23:14:31 Thomas.Klausner Exp $ */
+/* $LynxId: LYCurses.c,v 1.180 2014/07/24 22:08:24 tom Exp $ */
 #include <HTUtils.h>
 #include <HTAlert.h>
 
@@ -980,6 +980,7 @@ static int CALLBACK EnumWindowsProc(HWND hwnd, LPARAM lParam)
 {
     char this_title[256];
 
+    (void) lParam;
     if (GetWindowText(hwnd, this_title, sizeof(this_title) - 1) &&
 	(strncmp(dummyWindowTitle, this_title, 256) == 0)) {
 	currentWindowHandle = hwnd;
@@ -1180,7 +1181,7 @@ void restart_curses(void)
     keypad(LYwin, TRUE);
     lynx_enable_mouse(1);
 
-#if defined(USE_KEYMAPS)  
+#if defined(USE_KEYMAPS)
     if (-1 == lynx_initialize_keymaps()) {
 	endwin();
 	exit_immediately(EXIT_FAILURE);
@@ -1402,7 +1403,7 @@ void start_curses(void)
 #endif
 
 #if defined(USE_KEYMAPS) && defined(NCURSES_VERSION)
-#  if HAVE_KEYPAD
+#  ifdef HAVE_KEYPAD
 	/* Need to switch keypad on before initializing keymaps, otherwise
 	   when the keypad is switched on, some keybindings may be overriden. */
 	keypad(LYwin, TRUE);
diff --git a/src/LYLocal.c b/src/LYLocal.c
index 64fc6880..2ab20db4 100644
--- a/src/LYLocal.c
+++ b/src/LYLocal.c
@@ -1,5 +1,5 @@
 /*
- * $LynxId: LYLocal.c,v 1.127 2013/11/28 11:19:31 tom Exp $
+ * $LynxId: LYLocal.c,v 1.128 2014/07/24 22:06:43 tom Exp $
  *
  *  Routines to manipulate the local filesystem.
  *  Written by: Rick Mallett, Carleton University
@@ -424,6 +424,7 @@ static int LYExecv(const char *path,
     char *tmpbuf = 0;
 
 #if defined(__DJGPP__) || defined(_WINDOWS)
+    (void) msg;
     stop_curses();
     HTSprintf0(&tmpbuf, "%s", path);
     for (n = 1; argv[n] != 0; n++)
@@ -466,7 +467,7 @@ static int LYExecv(const char *path,
 	/*NOTREACHED */
 
     default:			/* parent */
-#if !HAVE_WAITPID
+#ifndef HAVE_WAITPID
 	while (wait(&wstatus) != pid) ;		/* do nothing */
 #else
 	while (-1 == waitpid(pid, &wstatus, 0)) {	/* wait for child */
diff --git a/src/LYUtils.c b/src/LYUtils.c
index f4f97b7e..4d6c01f6 100644
--- a/src/LYUtils.c
+++ b/src/LYUtils.c
@@ -1,5 +1,5 @@
 /*
- * $LynxId: LYUtils.c,v 1.266 2014/03/09 14:27:06 tom Exp $
+ * $LynxId: LYUtils.c,v 1.268 2014/07/24 22:30:44 tom Exp $
  */
 #include <HTUtils.h>
 #include <HTTCP.h>
@@ -42,6 +42,8 @@ extern int kbhit(void);		/* FIXME: use conio.h */
 #if !defined(kbhit) && defined(_WCONIO_DEFINED)
 #define kbhit() _kbhit()	/* reasonably recent conio.h */
 #endif
+#elif defined(__minix)
+#include <termios.h>		/* for struct winsize */
 
 #endif /* __MINGW32__ */
 
@@ -4584,7 +4586,7 @@ int win32_check_interrupt(void)
     return FALSE;
 }
 
-#if (!defined(__MINGW32__) && !defined(sleep)) || (defined(__MINGW32__) && !HAVE_SLEEP)
+#if (defined(__MINGW32__) && !defined(HAVE_SLEEP))
 void sleep(unsigned sec)
 {
     unsigned int i, j;
@@ -7856,7 +7858,7 @@ void get_clip_release()
 char *w32_strerror(DWORD ercode)
 {
 /*  __declspec(thread) necessary if you will use multiple threads */
-#ifdef __CYGWIN__
+#if defined(__CYGWIN__) || defined(__MINGW32__)
     static char msg_buff[256];
 
 #else
diff --git a/src/LYUtils.h b/src/LYUtils.h
index e24a1de7..173a9940 100644
--- a/src/LYUtils.h
+++ b/src/LYUtils.h
@@ -1,4 +1,4 @@
-/* $LynxId: LYUtils.h,v 1.96 2013/11/28 11:22:53 tom Exp $ */
+/* $LynxId: LYUtils.h,v 1.98 2014/07/24 22:10:20 tom Exp $ */
 #ifndef LYUTILS_H
 #define LYUTILS_H
 
@@ -304,7 +304,7 @@ extern "C" {
     extern void Define_VMSLogical(char *LogicalName, char *LogicalValue);
 #endif				/* VMS */
 
-#if ! HAVE_PUTENV
+#if !defined(HAVE_PUTENV)
     extern int putenv(const char *string);
 #endif				/* HAVE_PUTENV */
 
@@ -317,6 +317,11 @@ extern "C" {
 
 #if defined(_WINDOWS)
     extern int win32_check_interrupt(void);
+
+#if (defined(__MINGW32__) && !defined(HAVE_SLEEP))
+#undef sleep
+    void sleep(unsigned sec);
+#endif
 #endif
 
     /*