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

24 Коммитов

Автор SHA1 Сообщение Дата
Simon Tatham 91d16881ab Add missing 'static' on file-internal declarations.
sk_startup and sk_nextaddr are entirely internal to winnet.c; nearly
all of import.c and minibidi.c's internal routines should have been
static and weren't; {read,write}_utf8 are internal to charset/utf8.c
(and didn't even need separate declarations at all); do_sftp_cleanup
is internal to psftp.c, and get_listitemheight to gtkdlg.c.

While I was editing those prototypes anyway, I've also added missing
'const' to the 'char *' passphrase parameters in import,c.
2018-11-03 13:45:00 +00:00
Simon Tatham 20e36ae4a2 Fix a collection of type / format string mismatches.
Ilya Shipitsin sent me a list of errors reported by a tool 'cppcheck',
which I hadn't seen before, together with some fixes for things
already taken off that list. This change picks out all the things from
the remaining list that I could quickly identify as actual errors,
which it turns out are all format-string goofs along the lines of
using a %d with an unsigned int, or a %u with a signed int, or (in the
cases in charset/utf8.c) an actual _size_ mismatch which could in
principle have caused trouble on a big-endian target.
2017-06-20 07:05:39 +01:00
Simon Tatham 4d8782e74f Rework versioning system to not depend on Subversion.
I've shifted away from using the SVN revision number as a monotonic
version identifier (replacing it in the Windows version resource with
a count of days since an arbitrary epoch), and I've removed all uses
of SVN keyword expansion (replacing them with version information
written out by Buildscr).

While I'm at it, I've done a major rewrite of the affected code which
centralises all the computation of the assorted version numbers and
strings into Buildscr, so that they're all more or less alongside each
other rather than scattered across multiple source files.

I've also retired the MD5-based manifest file system. A long time ago,
it seemed like a good idea to arrange that binaries of PuTTY would
automatically cease to identify themselves as a particular upstream
version number if any changes were made to the source code, so that if
someone made a local tweak and distributed the result then I wouldn't
get blamed for the results. Since then I've decided the whole idea is
more trouble than it's worth, so now distribution tarballs will have
version information baked in and people can just cope with that.

[originally from svn r10262]
2014-09-24 10:33:13 +00:00
Simon Tatham 15f1bc7cdb It's probably well past time for this: change PuTTY's default
character set configuration to UTF-8, on both Windows and Unix, and
reorganise the dropdown lists in the Translation menu so that UTF-8
appears at the top (and Unix's odd "use font encoding" is relegated to
the bottom of the list like the special-purpose oddity it is).

[originally from svn r9843]
2013-05-25 14:03:19 +00:00
Simon Tatham c72d4b413f Support code page 852. Thanks to Tamas Tevesz.
[originally from svn r9326]
2011-10-14 07:03:29 +00:00
Simon Tatham c8d943ed9d Add some missing consts in character set handling.
[originally from svn r9291]
2011-09-16 19:18:52 +00:00
Ben Harris 91496d37c7 Propagate my ctype fixes (r8404) from libcharset.
[originally from svn r8405]
[r8404 == 7fce7161db885ed7f0fa0c06f27d58d789a23b62 in charset repository]
2009-01-11 14:20:34 +00:00
Simon Tatham 865b6b404d At last, merge the putty-gtk2 branch back into the trunk!
[originally from svn r8037]
2008-06-04 23:05:48 +00:00
Jacob Nevins 1e48a52b17 sbcsgen.pl was giving different results on different machines in the case
where two SBCS code points mapped to a single Unicode point.
Changed so that by default it favours the lower SBCS code point.
On ixion, this highlighted ambiguities in CS_MAC_THAI, CS_MAC_SYMBOL, and
CS_VISCII. Guessed at a preference for the first two and added "sortpriority"
directives. (No idea about VISCII.)

[originally from svn r6641]
[this svn revision also touched charset,filter,halibut,timber]
2006-04-26 23:01:06 +00:00
Jacob Nevins 40bcb7ebfd Update status of this library wrt other variants.
[originally from svn r6500]
2005-12-18 17:05:21 +00:00
Jacob Nevins 0f602f0368 CP866 is popular and small. Add it to both the general and PuTTY
implementations of libcharset, since we've had at least one request for
it in PuTTY.

[originally from svn r6499]
[this svn revision also touched charset,filter,halibut,timber]
2005-12-18 16:57:00 +00:00
Simon Tatham 8a99993c88 Remove .cvsignore files on all active branches.
[originally from svn r4788]
[this svn revision also touched bmbm,caltrap,charset,enigma,filter,fonts,golem,grunge,halibut,html,lj,local,misc,polyhedra,putty-website,putty-wishlist,puzzles,pycee,sdlgames,svn-tools,timber,tweak]
2004-11-16 15:29:14 +00:00
Simon Tatham 3faede1ec3 Bah. There's always one I forget to `cvs add'.
[originally from svn r3067]
2003-04-05 19:52:12 +00:00
Simon Tatham cf08c5a64a Fixed the printing and charset combo boxes in Unix PuTTY. (The
former by simply removing it; the latter by adding an enumeration
function to libcharset.) This has had slight `const' repercussions
on cp_name() and cp_enumerate() which might break the Mac build.

[originally from svn r3064]
2003-04-05 16:36:11 +00:00
Ben Harris 58c9d21f58 Don't pass NULL to strcmp. Instead, if the user passes a font of NULL,
only match table entries where the font is NULL.

[originally from svn r2725]
2003-01-25 19:21:56 +00:00
Simon Tatham e5012fa846 ... of course, that would be better still if I remembered to update
`nvalid'. Ahem.

[originally from svn r2428]
2003-01-02 17:07:24 +00:00
Simon Tatham a2afc03bdb A better solution to the problem of duplicated positions in
CS_ISO8859_1_X11: where two SBCS positions map to the same Unicode
code point, we now have a `sortpriority' hint which can tell
sbcsgen.pl which one it should preferentially generate when
converting back to SBCS.

[originally from svn r2427]
2003-01-02 16:56:29 +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
Simon Tatham 3deb118d4b Having painstakingly generated those reverse mapping tables in
sbcsdat.c, it would seem a shame not to actually use them. Ahem.
Thanks to Ben, without whose checkin in this area I'd have forgotten
completely :-)

[originally from svn r2404]
2003-01-01 17:03:27 +00:00
Ben Harris f8e3eee673 Add all the Mac OS simple single-byte character sets from ftp.unicode.org.
Also add the older variants described there, and the character set used by
the "VT100" font (old and new).

Since RFC 1345 defines "macintosh" to refer to the currency-sign variant
of Mac OS Roman, update our table to match.

[originally from svn r2403]
2003-01-01 16:24:01 +00:00
Ben Harris be63146e4f I have no idea what Simon thought he was doing casting what was once a
struct sbcs_data * (first element an array of unsigned long) into a
wchar_t *, but I think it's reasonably safe to assume that it was a
mistake.

[originally from svn r2399]
2002-12-31 22:37:27 +00:00
Ben Harris c66bf11fa1 Add internal prototypes to keep my compiler from complaining.
[originally from svn r2398]
2002-12-31 21:12:29 +00:00
Simon Tatham 548555ded4 Better, I think, to avoid mapping 0x00 -> U+0020 in the X11
nonstandard font encoding. 0x20 maps to it, so it's not as if it's
in short supply.

[originally from svn r2396]
2002-12-31 15:42:07 +00:00
Simon Tatham ad2bbc52a4 First draft of Unicode support in pterm. It's pretty complete: it
does UTF-8 copy and paste (falling back to normal strings if
necessary), it understands X font encodings and translates things
accordingly so that if you have a Unicode font you can ask for
virtually any single-byte encoding and get it (Mac-Roman pterm,
anyone?), and so on. There's work left to be done (wide fonts for
CJK spring to mind), but I reckon this is a pretty good start.

[originally from svn r2395]
2002-12-31 12:20:34 +00:00