Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mRemoteNG/PuTTYNG.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Tatham <anakin@pobox.com>2018-10-29 22:50:29 +0300
committerSimon Tatham <anakin@pobox.com>2018-11-03 16:45:00 +0300
commita6f1709c2f4d07a9312c5a6dd591fa0cf529808f (patch)
tree4ce0f5f3ce10c70eb35a7e90cee7fa4a144a96e2 /logging.c
parenta647f2ba1165393506c6c006c0bce4b82f5fa1ab (diff)
Adopt C99 <stdbool.h>'s true/false.
This commit includes <stdbool.h> from defs.h and deletes my traditional definitions of TRUE and FALSE, but other than that, it's a 100% mechanical search-and-replace transforming all uses of TRUE and FALSE into the C99-standardised lowercase spellings. No actual types are changed in this commit; that will come next. This is just getting the noise out of the way, so that subsequent commits can have a higher proportion of signal.
Diffstat (limited to 'logging.c')
-rw-r--r--logging.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/logging.c b/logging.c
index a04ca633..bf747b27 100644
--- a/logging.c
+++ b/logging.c
@@ -87,18 +87,18 @@ static void logfopen_callback(void *vctx, int mode)
char buf[256], *event;
struct tm tm;
const char *fmode;
- int shout = FALSE;
+ int shout = false;
if (mode == 0) {
ctx->state = L_ERROR; /* disable logging */
} else {
fmode = (mode == 1 ? "ab" : "wb");
- ctx->lgfp = f_open(ctx->currlogfilename, fmode, FALSE);
+ ctx->lgfp = f_open(ctx->currlogfilename, fmode, false);
if (ctx->lgfp) {
ctx->state = L_OPEN;
} else {
ctx->state = L_ERROR;
- shout = TRUE;
+ shout = true;
}
}
@@ -425,9 +425,9 @@ void log_reconfig(LogContext *ctx, Conf *conf)
conf_get_filename(conf, CONF_logfilename)) ||
conf_get_int(ctx->conf, CONF_logtype) !=
conf_get_int(conf, CONF_logtype))
- reset_logging = TRUE;
+ reset_logging = true;
else
- reset_logging = FALSE;
+ reset_logging = false;
if (reset_logging)
logfclose(ctx);
@@ -463,7 +463,7 @@ static Filename *xlatlognam(Filename *src, char *hostname, int port,
s = filename_to_str(src);
while (*s) {
- int sanitise = FALSE;
+ int sanitise = false;
/* Let (bufp, len) be the string to append. */
bufp = buf; /* don't usually override this */
if (*s == '&') {
@@ -501,7 +501,7 @@ static Filename *xlatlognam(Filename *src, char *hostname, int port,
* auto-format directives. E.g. 'hostname' can contain
* colons, if it's an IPv6 address, and colons aren't
* legal in filenames on Windows. */
- sanitise = TRUE;
+ sanitise = true;
} else {
buf[0] = *s++;
size = 1;