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

18 Коммитов

Автор SHA1 Сообщение Дата
Simon Tatham 84fed5c620 Fixes for the tree234 unit test: break its dependencies on half of the
rest of PuTTY, and fix a couple of format string type mismatches
pointed out by gcc.

[originally from svn r9911]
2013-07-11 17:24:32 +00:00
Jacob Nevins cd94e3bc3c Patch from Colin Watson intended to give a clean Unix compile with GCC 4.
(Since we choose to compile with -Werror, this is particularly important.)

I haven't yet checked that the resulting source actually compiles cleanly with
GCC 4, hence not marking `gcc4-warnings' as fixed just yet.

[originally from svn r7041]
2006-12-30 23:00:14 +00:00
Simon Tatham d36a4c3685 Introduced wrapper macros snew(), snewn() and sresize() for the
malloc functions, which automatically cast to the same type they're
allocating the size of. Should prevent any future errors involving
mallocing the size of the wrong structure type, and will also make
life easier if we ever need to turn the PuTTY core code from real C
into C++-friendly C. I haven't touched the Mac frontend in this
checkin because I couldn't compile or test it.

[originally from svn r3014]
2003-03-29 16:14:26 +00:00
Simon Tatham 3730ada5ce Run entire source base through GNU indent to tidy up the varying
coding styles of the various contributors! Woohoo!

[originally from svn r1098]
2001-05-06 14:35:20 +00:00
Simon Tatham 059998d17b Remove diagnostics and attempt to work around VC compiler bug :-(
[originally from svn r1096]
2001-05-03 10:10:53 +00:00
Simon Tatham 56a5e6fdf3 Extra diagnostics in the hope that we can track down the problem with
the nightlies. I must remember to take it all out again when we do!

[originally from svn r1095]
2001-05-02 14:45:25 +00:00
Simon Tatham 3abea3d4ea Having now compiled the last few days' changes with MSVC, it's turned
up a bunch of warnings, mostly unused variables. All fixed.

[originally from svn r1058]
2001-04-17 08:24:29 +00:00
Simon Tatham 7cd4f98ef6 countnode234() should politely return 0 when passed NULL. Was
breaking delpos234(empty_tree, 0).

[originally from svn r1054]
2001-04-16 21:24:38 +00:00
Simon Tatham 03c9b6107b Replace PuTTY's 2-3-4 tree implementation with the shiny new counted
one, in preparation for using it to speed up scrollback.

[originally from svn r1053]
2001-04-16 17:18:24 +00:00
Simon Tatham d5240d4157 Make memory management uniform: _everything_ now goes through the
smalloc() macros and thence to the safemalloc() functions in misc.c.
This should allow me to plug in a debugging allocator and track
memory leaks and segfaults and things.

[originally from svn r818]
2000-12-12 10:33:13 +00:00
Simon Tatham c1e5815add Make the new test suite's comment more accurate :-)
[originally from svn r663]
2000-10-02 13:57:41 +00:00
Simon Tatham 4a2ea18a51 Deletion case 2c can shift the root; case 3b is not the only case that
can do that. The bad case happens when you have a root node containing
only one actual element, and its two child nodes have only one element
each, and you try to delete the element in the root.

[originally from svn r660]
2000-10-02 11:47:30 +00:00
Simon Tatham 8084172c18 Shiny new test harness for the 2-3-4 tree
[originally from svn r658]
2000-10-02 11:46:10 +00:00
Simon Tatham aa203391c2 Keep parent pointers valid during deletion
[originally from svn r645]
2000-09-28 09:48:49 +00:00
Simon Tatham c9557bfc40 Fix tree corruption in the "really easy" case on deletion
[originally from svn r632]
2000-09-26 11:16:33 +00:00
Simon Tatham 2c76bd5b3a Fix a small bug in 2-3-4 tree enumeration
[originally from svn r630]
2000-09-26 10:05:48 +00:00
Simon Tatham 74a50d2d55 Delete should be void not void *; also use correct compare fn in find.
[originally from svn r594]
2000-09-15 10:48:42 +00:00
Simon Tatham 68ee8531fb 2-3-4 tree routines
[originally from svn r590]
2000-09-14 15:02:50 +00:00