X-Git-Url: https://asedeno.scripts.mit.edu/gitweb/?a=blobdiff_plain;f=windows%2Fwindefs.c;h=24a2ea4127ae01f9d69bf01f49a71b9e2a66f550;hb=3e22c99c9a3c28e042f2dc3a50fadf95e7c277e7;hp=2acc5e36618d495b5ba2900f91e041fca9bd1f8c;hpb=cb45b9cc253d6f661b2d90003b699c1558ca2bf4;p=PuTTY.git diff --git a/windows/windefs.c b/windows/windefs.c index 2acc5e36..24a2ea41 100644 --- a/windows/windefs.c +++ b/windows/windefs.c @@ -6,32 +6,26 @@ #include -FontSpec platform_default_fontspec(const char *name) +FontSpec *platform_default_fontspec(const char *name) { - FontSpec ret; - if (!strcmp(name, "Font")) { - strcpy(ret.name, "Courier New"); - ret.isbold = 0; - ret.charset = ANSI_CHARSET; - ret.height = 10; - } else { - ret.name[0] = '\0'; - } - return ret; + if (!strcmp(name, "Font")) + return fontspec_new("Courier New", 0, 10, ANSI_CHARSET); + else + return fontspec_new("", 0, 0, 0); } -Filename platform_default_filename(const char *name) +Filename *platform_default_filename(const char *name) { - Filename ret; if (!strcmp(name, "LogFileName")) - strcpy(ret.path, "putty.log"); + return filename_from_str("putty.log"); else - *ret.path = '\0'; - return ret; + return filename_from_str(""); } char *platform_default_s(const char *name) { + if (!strcmp(name, "SerialLine")) + return dupstr("COM1"); return NULL; }