Граф коммитов

91 Коммитов

Автор SHA1 Сообщение Дата
Ben Harris 0ea918fb3a const fallout from Simon's X forwarding changes.
[originally from svn r2540]
2003-01-11 14:08:07 +00:00
Simon Tatham 87f9446a26 Support XDM-AUTHORIZATION-1 for connecting to local X servers. If
we're going to be a security program, we can at least make a token
effort to use the most secure local X auth available! And I'm still
half-tempted to see if I can support it for remote X servers too...

[originally from svn r2537]
2003-01-11 09:31:54 +00:00
Simon Tatham 86977efa81 Introduce framework for authenticating with the local X server.
Windows and Mac backends have acquired auth-finding functions which
do nothing; Unix backend has acquired one which actually works, so
Plink can now do X forwarding believably.
(This checkin stretches into some unlikely parts of the code because
there have been one or two knock-on effects involving `const'. Bah.)

[originally from svn r2536]
2003-01-10 18:33:35 +00:00
Ben Harris 0d8ee2458a Implement get_window_title().
[originally from svn r2525]
2003-01-09 23:29:22 +00:00
Ben Harris c342678579 Forcibly close any TCP connections that are still open when PuTTY exits.
This saves leaving them lying around to crash the machine later.

[originally from svn r2524]
2003-01-09 23:04:34 +00:00
Ben Harris 34a96d4924 Use c2pstrcpy() rather than silly sprintf() tricks.
[originally from svn r2523]
2003-01-09 22:51:41 +00:00
Ben Harris 76a43ad512 c2pstr() is deprecated. Use c2pstrcpy() instead.
[originally from svn r2522]
2003-01-09 22:45:48 +00:00
Ben Harris 79cbd905e7 Take advantage of having control over the default font to do the job properly:
ask the system script what it's preferred monospaced font is, and use that
if possible.  Failing, that, try the Roman script system, and if that fails,
fall back to Monaco 9.

[originally from svn r2521]
2003-01-09 22:39:47 +00:00
Ben Harris 627566b1f6 Set PuTTY's canBackground flag so that it receives CPU time (to process
incoming data) while in the background.

[originally from svn r2520]
2003-01-09 19:27:29 +00:00
Ben Harris f11987f988 Install a notification procedure (ASR) on each TCP connection that wakes
PuTTY up when something happens.  This should allow it to receive data without
having to poll for it continuously.

[originally from svn r2519]
2003-01-09 19:26:39 +00:00
Simon Tatham 4d86f5979d I'm sick of all those #ifdefs in settings.c, and in any case plink
and pterm need at least one default setting to be _different_ (pterm
needs the default term type to be `xterm', while plink needs it to
be taken from $TERM). So here's a completely new alternative
mechanism for platform- and app-specific default settings. Ben will
probably want to check the integrity of the Mac port, since I've
fiddled with it without testing that it still compiles.

[originally from svn r2513]
2003-01-09 18:06:29 +00:00
Ben Harris c601d72463 Add PuTTYtel binaries.
[originally from svn r2503]
2003-01-08 23:58:50 +00:00
Ben Harris f4384cb6c7 Rather useless entropy-collection functions for Mac OS. These need work.
[originally from svn r2502]
2003-01-08 23:56:48 +00:00
Ben Harris 697794abbf Fairly major hackery to get SSH going on the Mac. Half the support
functions are only dummy stubs, but it's still minimally usable.  At
least, as long as you don't want to do anything complex like logging out.

[originally from svn r2500]
2003-01-08 22:46:12 +00:00
Ben Harris dd39a1919d sshsha.c and sshmd5.c compile fine on PowerPC now.
[originally from svn r2471]
2003-01-05 15:31:45 +00:00
Ben Harris 30bff47c89 Add reception support for MacTCP. Now I can log in over TELNET, just about.
There are still lots of things to fix, like urgent data or the fact that
everything seems to happen one keypress too late, but this is an important
milestone.

[originally from svn r2458]
2003-01-05 12:53:38 +00:00
Ben Harris a7ba273b5b When looking for the correct backend to use, look in the configuration
structure for the session, not the almost-dead global cfg.

[originally from svn r2457]
2003-01-05 11:31:51 +00:00
Ben Harris ac85d9b8c9 Second work-in-progress MacTCP commit. We can now open a connection, but
not transfer any data across it.

[originally from svn r2456]
2003-01-05 10:52:56 +00:00
Ben Harris ba15f25503 Beginnings of a MacTCP network layer. This has all of the DNS interface
present, including stuff to find and load the MacTCP DNR.  Actually making
a TCP connection is still unimplemented, though, and much testing remains
to be done.

[originally from svn r2452]
2003-01-04 19:51:20 +00:00
Ben Harris 94b7de24f1 Add a vsnprintf() for the Mac, which doesn't have one of its own. This is
the NetBSD kernel printf, which is integer-only and under a Berkeley-style
(now 3-clause) copyright owned by UCB.  This has only been compile-tested,
but almost all of my changes were in the definitions at the top (the exception
being to remove tty output).  This lacks 64-bit support because the Apple
68K C compiler, SC, lacks it too.

[originally from svn r2451]
2003-01-04 19:01:45 +00:00
Ben Harris a952ead769 Provide a version of stricmp() and strnicmp() for Mac OS, which doesn't have
its own.  These are from NetBSD's libc, and have a standard (now 3-clause)
Berkeley licence.

Also provide a definition of DWORD and a better definition of BYTE.

[originally from svn r2449]
2003-01-04 17:24:49 +00:00
Ben Harris e82053be5c <MacTypes.h> says we should use NULL rather than nil in C, so do that.
[originally from svn r2444]
2003-01-04 12:45:11 +00:00
Ben Harris e13dfa3562 Re-arrange the sums in the size tip code so as to ensure that we're always do
division on positive numbers, hence avoiding nasty problems of rounding
towards zero when I wanted rounding down.

[originally from svn r2443]
2003-01-04 00:48:13 +00:00
Ben Harris 7c40e3434d Small simplification in mac_init().
[originally from svn r2442]
2003-01-04 00:31:04 +00:00
Ben Harris 561029bfdf Correct handling of Mac OS 8.5 Window Manager and Control Manager. The new
functions turn out to be available only to PowerPC applications, through
WindowsLib and ControlsLib respectively, so we weak-link against those in
the obvious way.

[originally from svn r2441]
2003-01-04 00:13:18 +00:00
Ben Harris 0a6e82b4dd Update copyright notices that both Owen and Simon managed to miss.
_How_ many copies of the licence do we need? *grin*

[originally from svn r2435]
2003-01-03 12:20:14 +00:00
Ben Harris 8af9c0a745 Pull in Script.r so we can use verBritain in the 'vers' resources rather
than hardcoding 2.

[originally from svn r2432]
2003-01-03 00:40:52 +00:00
Ben Harris 375185cf9f Any Mac that can handle CFM-68K code must have at least a 68020 CPU, and hence
be equipped with Color QuickDraw, as are all PowerPC systems.  Hence, don't
bother with support for basic QuickDraw in the CFM-68K and PowerPC builds.

[originally from svn r2431]
2003-01-02 23:52:44 +00:00
Ben Harris 44a1e7fff2 Add a prototype for init_ucs().
[originally from svn r2430]
2003-01-02 23:39:53 +00:00
Ben Harris 19ed21b98a Having tested it, note that the Classic 68K build seems to work on Mac OS X
now.  Also describe more generally which builds work where.

[originally from svn r2429]
2003-01-02 18:09:21 +00:00
Ben Harris 0416b77c7f If for some reason do_text() fails to translate from Unicode to the font
encoding, have it go through the rest of its motions with an empty string
anyway, so as to at least give a sensible empty box of the right colour.

If SetFallbackUnicodeToText() fails, switch over to using the charset
library, hence avoiding problems in do_text().

If the version of the Unicode Converter we're using doesn't understand about
interrupt-safe fallback functions, don't try to tell it we've got one.  This
prevents SetFallbackUnicodeToText() from failing on systems with old Unicode
Converters.

[originally from svn r2414]
2003-01-02 00:33:40 +00:00
Ben Harris 7bdd57f300 The redirection operator I wanted was >>, not >.
[originally from svn r2411]
2003-01-01 20:28:52 +00:00
Ben Harris b002b19ff9 Ignore .rsrc files.
[originally from svn r2410]
2003-01-01 20:26:55 +00:00
Ben Harris 0ea7e35008 Add a mechanism for determining which charset to use for a given Mac OS font,
and use it.

[originally from svn r2409]
2003-01-01 19:51:13 +00:00
Ben Harris d8413715a9 Remove a couple of unnecessary casts that my compiler seems to have taken
exception to.

[originally from svn r2402]
2003-01-01 11:45:43 +00:00
Ben Harris 491f7be9fc Use the shiny new character-set library to handle conversion from Unicode
to Mac OS Roman for display if the Unicode Converter isn't around.  Support
for Mac character sets other than Roman (e.g. the variant used by the Apple
VT100 font) is still absent.

[originally from svn r2401]
2002-12-31 22:49:03 +00:00
Ben Harris 3777de60cb Add a small comment explaining my failure to find any way to get QuickDraw
to give me the missing-character glyph for a font.
While I'm here, change the character we substitute for unmappable ones
to '.', since that's what the charset library uses.

[originally from svn r2397]
2002-12-31 20:11:38 +00:00
Ben Harris 6c1c86f23d Add a minimalist settings dialogue, which contains a single button
marked "open".  Still, it seems to work.

[originally from svn r2392]
2002-12-31 01:40:14 +00:00
Ben Harris d807c97bfd Remove mentions of files and functions that no longer exist.
[originally from svn r2391]
2002-12-30 23:33:13 +00:00
Ben Harris fc02176fcd No need to compile resources manually now.
[originally from svn r2390]
2002-12-30 23:15:46 +00:00
Ben Harris 47f459bb5f Add support for compiling 'vers' resources into Mac applications. This is
needlessly complex because Rez's preprocessor doesn't do either ANSI or K&R
stringification, and the MPW Shell isn't much good as shells go.

Also make _all_ the Mac executables depend on reources, not just the
Classic 68K one.

[originally from svn r2389]
2002-12-30 23:14:11 +00:00
Ben Harris 14432c234a Set the default directory to somewhere useful (the PuTTY saved sessions
folder) when we start up.

[originally from svn r2388]
2002-12-30 19:01:44 +00:00
Ben Harris 71d699c28c Add an "open" command to the "file" (now "session") menu on the Mac to
open an existing saved session.  This has entailed adding an extra hook to
settings.c to allow for loading settings other than by name.

[originally from svn r2387]
2002-12-30 18:21:17 +00:00
Ben Harris d5d52933dd Remove a spurious reference to a variable I've removed.
[originally from svn r2386]
2002-12-30 15:41:52 +00:00
Ben Harris 6ca089d035 Add spaces to system include lines to that mkfiles.pl doesn't try to
follow them (silly Rez can't do angle-bracket includes).

[originally from svn r2384]
2002-12-30 14:17:51 +00:00
Ben Harris cababe03ef Add various files produced by the build system.
[originally from svn r2382]
2002-12-29 19:19:10 +00:00
Ben Harris ecdb9ce7b1 Don't try to call TerminateUnicodeConverter() in the CFM world: it isn't there.
[originally from svn r2381]
2002-12-29 19:14:56 +00:00
Ben Harris d1eddb0958 Brutally simplify out all the junk that MPW left here when it first wrote this
file.

[originally from svn r2380]
2002-12-29 19:11:40 +00:00
Ben Harris b838180aa0 Add support for building a CFM-68K version of PuTTY, which is rather smaller
than the Classic 68K version.  This requires installing more bits of the
Text Encoding Converter SDK, since Apple seem to have forgotten to put _any_
68k bits for it, either CFM or Classic, in Universal Interfaces.

Also don't bother linking against libraries we don't seem to need.

[originally from svn r2379]
2002-12-29 19:01:33 +00:00
Ben Harris 9b45be7987 Substantial overhaul of Mac build system. We now have working PowerPC builds,
and optimisation (for size) enabled.

[originally from svn r2378]
2002-12-29 15:44:15 +00:00