mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-09 15:50:40 -08:00
Fix compilation warnings.
* lib-src/test-distrib.c (cool_read): * lib-src/movemail.c (main, concat): * lib-src/make-docfile.c (scan_file, write_c_args): * emacsclient.c (get_server_config): Fix -Wconversion warning. (egetenv): Move conditional definition earlier. (progname): Use const. * lib-src/sorted-doc.c (xstrdup): Use const.
This commit is contained in:
parent
c1ae068bbb
commit
728a982db4
6 changed files with 25 additions and 18 deletions
|
|
@ -39,6 +39,9 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
|
|||
# define CLOSE_SOCKET closesocket
|
||||
# define INITIALIZE() (initialize_sockets ())
|
||||
|
||||
char *w32_getenv (char *);
|
||||
#define egetenv(VAR) w32_getenv(VAR)
|
||||
|
||||
#else /* !WINDOWSNT */
|
||||
|
||||
# include "syswait.h"
|
||||
|
|
@ -62,6 +65,8 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
|
|||
# define WCONTINUED 8
|
||||
# endif
|
||||
|
||||
#define egetenv(VAR) getenv(VAR)
|
||||
|
||||
#endif /* !WINDOWSNT */
|
||||
|
||||
#undef signal
|
||||
|
|
@ -86,13 +91,6 @@ char *getenv (const char *), *getwd (char *);
|
|||
char *(getcwd) (char *, size_t);
|
||||
#endif
|
||||
|
||||
#ifdef WINDOWSNT
|
||||
char *w32_getenv (char *);
|
||||
#define egetenv(VAR) w32_getenv(VAR)
|
||||
#else
|
||||
#define egetenv(VAR) getenv(VAR)
|
||||
#endif
|
||||
|
||||
#ifndef VERSION
|
||||
#define VERSION "unspecified"
|
||||
#endif
|
||||
|
|
@ -119,7 +117,7 @@ char *w32_getenv (char *);
|
|||
|
||||
|
||||
/* Name used to invoke this program. */
|
||||
char *progname;
|
||||
const char *progname;
|
||||
|
||||
/* The second argument to main. */
|
||||
char **main_argv;
|
||||
|
|
@ -752,7 +750,7 @@ send_to_emacs (HSOCKET s, const char *data)
|
|||
{
|
||||
while (data)
|
||||
{
|
||||
int dlen = strlen (data);
|
||||
size_t dlen = strlen (data);
|
||||
if (dlen + sblen >= SEND_BUFFER_SIZE)
|
||||
{
|
||||
int part = SEND_BUFFER_SIZE - sblen;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue