Directory trunk/crossfire/socket/

Directory Created:
1999-04-02 14:10
Directory Deleted:
2006-09-19 02:24
Total Files:
Deleted Files:
Lines of Code:


Lines of Code

trunk/crossfire/socket/ Lines of Code


Author Changes Lines of Code Lines per Change
Totals 361 (100.0%) 8458 (100.0%) 23.4
mwedel 144 (39.9%) 4354 (51.5%) 30.2
tchize 22 (6.1%) 1253 (14.8%) 56.9
michtoen 28 (7.8%) 730 (8.6%) 26.0
ryo_saeba 44 (12.2%) 573 (6.8%) 13.0
akirschbaum 55 (15.2%) 482 (5.7%) 8.7
cvs 32 (8.9%) 478 (5.7%) 14.9
uid200 9 (2.5%) 236 (2.8%) 26.2
cavesomething 8 (2.2%) 216 (2.6%) 27.0
garbled 4 (1.1%) 63 (0.7%) 15.7
reeve 2 (0.6%) 18 (0.2%) 9.0
avogl 1 (0.3%) 12 (0.1%) 12.0
smacfiggen 2 (0.6%) 10 (0.1%) 5.0
quinet 1 (0.3%) 10 (0.1%) 10.0
gros 1 (0.3%) 9 (0.1%) 9.0
jec 4 (1.1%) 7 (0.1%) 1.7
mids 2 (0.6%) 6 (0.1%) 3.0
azzie 1 (0.3%) 1 (0.0%) 1.0
jbontje 1 (0.3%) 0 (0.0%) 0.0

Most Recent Commits

mwedel 2006-09-19 02:24 Rev.: 4942

make branche directories, delete old trunk.

0 lines of code changed in 13 files:

  • trunk/crossfire/socket: .cvsignore (del), (del), (del), README (del), image.c (del), info.c (del), init.c (del), item.c (del), loop.c (del), lowlevel.c (del), metaserver.c (del), request.c (del), sounds.c (del)
mwedel 2006-09-04 02:21 Rev.: 4876

Bulk of this change is updating some files to use draw_ext_info() - all
future code should use this, since there is no real reason not to and
it provides additional features. One notable change - reversed the
order of the new and old formats in draw_ext_info_format() - the
order was different than that of draw_ext_info(), which leads to confusion.
draw_ext_info_format() wasn't used in many places, so easier to change
that than all the draw_ext_info() calls. Only another 1200
new_draw_info calls left in the server.
doc/mediaTags: Fix some typos, clarify some behaviour (the way it works
now so that there will not be confusion in the future).
include/define.h: Remove MSG_ tags - moved to newclient.h
include/newclient.h: Synchronize with client version. Add MSG_ defines
include/newserver.h: Move some defines from here to newclient.h
server/apply.c: Reverse format parameters to draw_ext_info_format() calls.
server/c_misc.c: Rewrite to use draw_ext_info{_format} - this allows nice
formatting of tables, etc. Also general style cleanups, clarify some
messages. in help_topics(), don't do linewrap - let the client
handle it. remove bug_report() function - no longer used. Remove
explore_mode() - wasn't used. Move command_style_map_info() to
c_wiz.c since it is a wiz only command.
server/c_wiz.c: As per above, move command_style_map_info() to this file
since it is a wiz command.
server/player.c: Reverse format parameters to draw_ext_info_format() calls.
server/shop.c: Update to use draw_ext_info{_format} instead of new_draw_info()
socket/info.c: Reverse format parameters in draw_ext_info_format().
Update va_start() to use new last parameter. Remove call to
strip_media() if the client supports the tag - that should only be
used if the client does not support the tag.
socket/request.c: remove commented out MSG_TYPE values.
MSW 2006-09-03

35 lines of code changed in 2 files:

  • trunk/crossfire/socket: info.c (+34 -21), request.c (+1 -7)
ryo_saeba 2006-09-02 09:25 Rev.: 4860

Apply patch #1550716 (Frequent crashes after client disconnects) courtesy Mark Kidder

9 lines of code changed in 1 file:

  • trunk/crossfire/socket: lowlevel.c (+9 -5)
quinet 2006-08-25 16:28 Rev.: 4836

configure, aclocal.m4, utils/config.guess, utils/config.sub,
utils/, include/, */ regenerated using
slightly newer versions of libtoolize, aclocal, automake and autoconf.

10 lines of code changed in 1 file:

  • trunk/crossfire/socket: (+10 -6)
ryo_saeba 2006-08-22 16:45 Rev.: 4831

Fix for bug #1528636 (Invisible player disappears from map view)

7 lines of code changed in 1 file:

  • trunk/crossfire/socket: request.c (+7)
ryo_saeba 2006-08-08 05:05 Rev.: 4763

Feature request #821645 (change password command)

3 lines of code changed in 1 file:

  • trunk/crossfire/socket: request.c (+3)
ryo_saeba 2006-07-29 05:13 Rev.: 4727

Add .cvsignore files, courtesy Rapha��l Quinet - quinet

0 lines of code changed in 1 file:

  • trunk/crossfire/socket: .cvsignore (new)
akirschbaum 2006-07-16 03:46 Rev.: 4676

Fix player count reporting to the metaserver. It now excludes connections with
not-yet-logged-in players and AFK/WIZ/BOT players.

10 lines of code changed in 1 file:

  • trunk/crossfire/socket: metaserver.c (+10 -3)
mwedel 2006-06-05 01:28 Rev.: 4626

Clean up some compiler warnings. Most of the changes are related to replaced
%lld with FMT64 defines so that the format will be correct, no matter if
the 64 bit type is a long, long long, or if this is windows. #if 0 out a
bunch of code that isn't used.
common/exp.c: Replaced lld with FMT64
common/holy.c: #if 0 out baptize_altar(). Add banner copyright at top of file.
common/info.c, common/item.c, common/loader.l, common/loader.c, common/map.c:
common/porting.c Replaced lld with FMT64
common/time.c: Replace a bunch of variables declared as longs to be uint32.
Update various sprintf appropriately.
include/global.h: Add FMT64 and FMT64U as appropriate for different systems.
Change max_time to be a uint32
include/sockproto.h, include/sproto.h: rebuilt
server/apply.c: #if 0 out monster_apply_special
server/c_range.c: Add != 0 in assignment if statement - same meaning, clearer
on intention and avoids compiler warning.
server/c_wiz.c: Update command_kick() to take const char. Update command_speed()
to operate properly based on max_time being a uint32. Update various lld
to FMT64. Clarify ambiguous if/if/else statement in command_insert_into()
server/commands.c: Add cast to command_kick for new function prototype. #if
0 out find_command(), parse_string(), parse_command()
server/disease.c: #if 0 out find_disease(), reduce_symptoms()
server/egoitem.c: #if 0 out create_artifact(). Add copyright at top of file.
server/gods.c: #if 0 out get_god()
server/hiscore.c: Replace lld with FMT64
server/login.c: #if 0 out create_savedir_if_needed()
server/resurrection.c: Replace lld with FMT64. #if 0 out dead_character() and
server/server.c: Remove info_keys() - hasn't been used in a long time. #if 0
out process_active_maps()
server/skill_util.c: Replace lld with FMT64
server/spell_util.c: #if 0 out check_spell_effect()
server/weather.c: #if 0 out feather_map(). Fix what I suspect is an error
in worldmap_to_weathermap() to skip over starting slashes.
socket/image.c: Add a fair number of char * casts to suppress warnings.
socket/init.c: Change buflen in init_connection() to socklen_t to match
function prototype. Add some char * casts.
socket/loop.c: Add some char * casts.
MSW 2006-06-04

18 lines of code changed in 3 files:

  • trunk/crossfire/socket: image.c (+8 -8), init.c (+2 -2), loop.c (+8 -8)
akirschbaum 2006-06-01 15:55 Rev.: 4618

Do not merge locked and unlocked items.

11 lines of code changed in 1 file:

  • trunk/crossfire/socket: item.c (+11 -1)
mwedel 2006-05-30 02:16 Rev.: 4608

Various bug fixes, related to the new map display code.
common/loader.c, common/loader.l: Add map_layer attribute so object can
override what layer it should go on (fix for levitation boots).
common/map.c: Add support for map_layer to override layering. Fix bug
where if there were more objects than would fit on a layer, not all
would be drawn (same object was duplicated onto multiple layers).
common/object.c: Add check for ob->map_layer in can_merge()
include/map.h: Add extern declaration for map_layer_name[]
include/object.h: Add map_layer to object.
socket/request.c: In map1 compatibility mode, make sure we always
send the player.
MSW 2006-05-29

8 lines of code changed in 1 file:

  • trunk/crossfire/socket: request.c (+8 -2)
akirschbaum 2006-05-21 05:35 Rev.: 4577

Make socket handling more robust.

72 lines of code changed in 8 files:

  • trunk/crossfire/socket: image.c (+10 -12), info.c (+2 -2), init.c (+2 -2), item.c (+7 -7), loop.c (+4 -3), lowlevel.c (+8 -8), request.c (+38 -29), sounds.c (+1 -1)
akirschbaum 2006-05-21 05:07 Rev.: 4576

Fix reference to undefined type name.

1 lines of code changed in 1 file:

  • trunk/crossfire/socket: request.c (+1 -1)
ryo_saeba 2006-05-20 07:37 Rev.: 4574

Add a bot flag, to not count in metaserver information

5 lines of code changed in 3 files:

  • trunk/crossfire/socket: init.c (+1), metaserver.c (+1 -1), request.c (+3 -1)
mwedel 2006-05-18 00:27 Rev.: 4568

This commit adds support for the map2 protocol command (10 layer map).
This changes how the data is stored and sent to the client. This also
implements the idea of client handling map animations, so adds some object
flags so that the server knows if it should let the client handle animations
or not. Support for the original map protocol command is removed.
aclocal.m4: rebuilt Add checks for zlib.h, libz - not used right now, but will
probably be used in the future, so no reason to remove it.
common/loader.l: Add client_anim_sync, client_anim_random FLAGS.
common/map.c: Add add_face_layer() to set face for a layer. Redo/simplify
update_position to store faces away based on layering criteria.
common/time.c: Replace long pticks with a uint32, since size of a long will
vary, and we now send pticks to the client as a 32 bit value.
crossedit/CrEdit.c: Update the draw logic based on the fact there are more
layers now.
crossedit/Edit.c: Comment out some code that probably should be fixed.
Replace calls of SET_MAP_FACE with SET_MAP_FACE_OBJ
doc/Developers/protocol: Updated with map2, tick protocol additions.
Reorganize the parameters in the setup protocol command so they are now
listed in alphabetical order.
include/ Add HAVE_ZLIB_H define.
include/define.h: Update for the FLAG_CLIENT_ANIM values.
include/face.h: Remove MapLook structure - no longer used.
include/global.h: change extern type for pticks from long to uint32
include/map.h: Change MAP_LAYERS to 10. Add definitions for what each
map layer is. Remove GET/SET_MAP_FACE macro - no longer used,
returns pointer to all the object info for the space. Remove
faces from MapSpace structure.
include/newclient.h: Update with new defines used for map2 protocol
include/newserver.h: Change type of faces in map_cell_struct to be
uint16 to be consistent. Change 'count' to 'darkness' to more
accurately describe what it represents. Add MAP2_COORD_OFFSET
define. Add Map2Cmd to MapMode enum. Add map_scroll_x/y
to socket structure so we send those as part of map2 command.
Add tick field to socket structure to know if we should send
tick data to the client.
server/login.c: Remove extern long pticks declaration - declared
in global.h - don't need to declare it again locally.
socket/info.c: Rewrite magic map code to use GET_MAP_FACE_OBJ
instead of GET_MAP_FACE macros.
socket/init.c: Initialize new fields in socket structure to 0.
socket/loop.c: If client wants tick data sent, send one each tick.
socket/request.c: Add setup responses for tick, map2 requests. Remove some
extra code in Map1a setup. Send error message to client if not using
at least Map1 protocol level. Modify map_newmap_cmd() to clear
scroll information when using Map2. Remove original (map0) protocol
logic. Update map_clearcell() to clear all 10 layers. Replace
MAX_LAYERS with MAP_LAYERS. Add add_head() to remove some of the
complication from update_space(). Add code in draw_client_map1()
to find which 3 layers to send to the client from the 10 we now have.
Add map2_add_ob(), map2_delete_layer(), check_space_for_heads(),
draw_client_map2() to handle map2 protocol. Add send_tick() -
sends tick to client, but also forces flush of data to reduce lag.
utils/config.guess.utils/config.sub,utils/ rebuilt
MSW 2006-05-15

716 lines of code changed in 4 files:

  • trunk/crossfire/socket: info.c (+19 -14), init.c (+3), loop.c (+2 -1), request.c (+692 -360)
akirschbaum 2006-05-13 16:21 Rev.: 4565

Fix server crash when sending addspell command(s).

8 lines of code changed in 2 files:

  • trunk/crossfire/socket: lowlevel.c (+1 -1), request.c (+7 -12)
ryo_saeba 2006-05-05 04:41 Rev.: 4559

Second part of patch #1453869 courtesy Stefan Huehner (shuehner)

11 lines of code changed in 4 files:

  • trunk/crossfire/socket: info.c (+6 -6), item.c (+3 -3), request.c (+1 -1), sounds.c (+1 -1)
tchize 2006-05-03 16:50 Rev.: 4554

Added autogeneration of html and text report for test process.

6 lines of code changed in 1 file:

  • trunk/crossfire/socket: (+6)
tchize 2006-03-22 18:06 Rev.: 4546

updated to automatically check availability of a few headers required by crossedit
Basically, it tries to compile a test code having only includes of xaw, posix, etc. Should be
enough to prevent most crossedit compilation issue but not perfect. (Should check version of lib and
try a few methods on them). crossedit/ and test/unit/crossedit are skipped by make if test fail.

1 lines of code changed in 1 file:

  • trunk/crossfire/socket: (+1)
tchize 2006-03-21 17:46 Rev.: 4543

Initial commit of unit tests (see doc/Developers/testplans)
This is it, initial commit of unit test framework. It contains empty testcases
for all unit tests. See test/unit/check_shstr.c for a completed example unit test :)

7 lines of code changed in 1 file:

  • trunk/crossfire/socket: (+7 -1)
akirschbaum 2006-03-18 20:51 Rev.: 4541

Apply patch by Stefan Huehner: add const where appropriate.

16 lines of code changed in 2 files:

  • trunk/crossfire/socket: loop.c (+7 -7), lowlevel.c (+9 -9)
ryo_saeba 2006-03-18 10:05 Rev.: 4534

Massive cleaning of code. Shouldn't be any functional change.

138 lines of code changed in 7 files:

  • trunk/crossfire/socket: image.c (+13 -14), info.c (+3 -3), init.c (+8 -8), item.c (+9 -8), loop.c (+50 -49), lowlevel.c (+8 -7), request.c (+47 -45)
ryo_saeba 2006-03-14 12:12 Rev.: 4530

Fix memory leak and uninitialized variable

2 lines of code changed in 2 files:

  • trunk/crossfire/socket: (+1 -3), init.c (+1)
mwedel 2006-03-14 02:41 Rev.: 4520

Fix bug/exploit in setup command. We were strcat'ing back data provided
by the client.
socket/request.c: Modify SetUp() to use safe_strcat() - eliminates buffer
overflow issues. Add some char* casts to spell/skill requestinfo
to eliminate compiler warnings. Add IP address to log for incoming
MSW 2006-03-13

41 lines of code changed in 1 file:

  • trunk/crossfire/socket: request.c (+41 -40)
cavesomething 2006-02-20 18:35 Rev.: 4479

A better fix for sending the spell skill data

1 lines of code changed in 1 file:

  • trunk/crossfire/socket: request.c (+1 -3)
cavesomething 2006-02-20 13:43 Rev.: 4475

fix crash when sending spell info if there no associated skill

10 lines of code changed in 1 file:

  • trunk/crossfire/socket: request.c (+10 -7)
akirschbaum 2006-02-10 18:59 Rev.: 4442

Apply slightly modified patch #1428309 (code-cleanup: const, static) by
Stefan Huehner: add const/static to functions/variables. Remove some type

10 lines of code changed in 3 files:

  • trunk/crossfire/socket: info.c (+7 -7), loop.c (+2 -2), request.c (+1 -1)
mwedel 2006-02-07 02:54 Rev.: 4427

Code that adds transports. Transports are described more in detail in
loader.l: Add new move type ('boat'). Update move_name field to be aware of
this type.
common/object.c: Unrelated to transport, but more apparant with transports -
fix bug with insert_ob_in_map() and multipart objects - we now only
try to fix up map and coordinates if the provided coordinates are
out of the map. Before, function would always use the passed
map for multipart objects, which is incorrect if we have already
set valid coordinates.
doc/Developers/objects: Update notes for TRANSPORTS. Update move
information to include MOVE_BOAT.
include/define.h: Add type TRANSPORT. Add MOVE_BOAT.
include/player.h: Add transport field to player structure.
include/sproto.h: rebuilt.
server/apply.c: Add code to handle applying of transports. Update
apply_below to apply transport if player is on one.
server/attack.c: Update hit_map() to look for transports, and hit any
players with the damage.
server/c_object.c: Update put_object_in_sack() to also handle TRANSPORTS
so that code can be re-used.
server/move.c: Fix handling of multipart objects in move_object() -
old code didn't work right with multipart objects moving along seams
of tiled maps. Add code to move_ob() to update player map position
for all players in a moving transport.
server/player.c: Update move_player_attack() too check of player is
in tranport, and use that for map and location information. Update
move_player() to handle speed related issues with transports.
server/time.c: Add code to credit time back to TRANSPORT objects since
we remove time in move_player() for TRANSPORTS.
socket/item.c: Add add_object_to_socklist() so that same code isn't
reproduced in 3 different places in the file. Update draw_look()
to handle transports - send transport object itself, then objects
in transport. Update esrv_send_inventory() and esrv_send_item()
to use add_object_to_socklist(). Update esrv_get_ob_from_count() to look
for objects in transport if player is in transport.
socket/loop.c: Remove checking of pl->map status, since draw_client_map()
does that, and we need to handle if the player is in a transport.
socket/request.c: Handle map drawing if player is in a transport.
MSW 2006-02-06

133 lines of code changed in 3 files:

  • trunk/crossfire/socket: item.c (+118 -169), loop.c (+4 -2), request.c (+11 -5)
cavesomething 2006-01-30 12:00 Rev.: 4410

prevent unlimited login attempts by dropping the connection after too many password failures. Document the itemcmd setup flag, and improve that for the item and item2 commands

16 lines of code changed in 2 files:

  • trunk/crossfire/socket: init.c (+1), loop.c (+15 -1)
akirschbaum 2006-01-13 16:26 Rev.: 4391

socket/request.c: In ReplyCmd() make sure the reply does not cause a buffer

1 lines of code changed in 1 file:

  • trunk/crossfire/socket: request.c (+1 -1)
cavesomething 2006-01-13 15:42 Rev.: 4389

fix a crash bug in addspell packet formation

7 lines of code changed in 1 file:

  • trunk/crossfire/socket: request.c (+7 -3)
mwedel 2006-01-13 02:10 Rev.: 4384

Quick change to include proper byte counts in packet sizes for
spell - see if it will reduce the crashes.
MSW 2006-01-12

6 lines of code changed in 1 file:

  • trunk/crossfire/socket: request.c (+6 -2)
mwedel 2006-01-11 03:12 Rev.: 4374

Make function ANSI C compliant.
MSW 2006-01-11

2 lines of code changed in 1 file:

  • trunk/crossfire/socket: request.c (+2 -1)
cavesomething 2006-01-09 14:35 Rev.: 4358

spell listing support

182 lines of code changed in 3 files:

  • trunk/crossfire/socket: init.c (+1), loop.c (+1), request.c (+180 -2)
akirschbaum 2006-01-08 16:02 Rev.: 4343

include/newserver.h, socket/{init.c,request.c}: Remove unused fields ext2 and
ext_title_flag from NewSocket structure.

0 lines of code changed in 2 files:

  • trunk/crossfire/socket: init.c (-2), request.c (-6)
akirschbaum 2005-12-11 14:11 Rev.: 4132

Fix buffer overflows which can be triggered remotely.

8 lines of code changed in 1 file:

  • trunk/crossfire/socket: loop.c (+8 -8)
akirschbaum 2005-12-10 09:27 Rev.: 4112

common/object.c, server/{pets.c,player.c,spell_attack.c,time.c},
socket/request.c: Properly check for P_OUT_OF_MAP after calling

2 lines of code changed in 1 file:

  • trunk/crossfire/socket: request.c (+2)
akirschbaum 2005-12-07 13:25 Rev.: 4093

Apply modified patch #1293774 (Kick banned hosts at once) by Thomas Equeter:
disconnect new connection for banned host right after connecting. Also add
support for user name in ban files.

20 lines of code changed in 2 files:

  • trunk/crossfire/socket: init.c (+2 -4), loop.c (+18 -2)
akirschbaum 2005-12-05 18:34 Rev.: 4092

Apply patch #1371956 (code cleanup patch) by Stefan Huehner: fix old-style
function declarations and prototypes to proper Ansi C syntax. This patch
allows the compiler to check function arguments and also removes some warnings
when compiling with -Wstrict-prototypes.

9 lines of code changed in 5 files:

  • trunk/crossfire/socket: image.c (+2 -2), init.c (+2 -2), loop.c (+2 -2), lowlevel.c (+1 -1), metaserver.c (+2 -2)
akirschbaum 2005-10-28 14:08 Rev.: 3937

Fix compiler warnings. Most changes do not change the program (remove unused
variables, convert "if(x = y)" into "x = y; if(x)"); a few actually fix
(possible) problems (fix uninitialized variables, fix printf format
specifiers, fix mismatches between signed and unsigned variables, add missing
return and default statements).

8 lines of code changed in 2 files:

  • trunk/crossfire/socket: loop.c (+2 -2), request.c (+6 -1)

(162 more)

Generated by StatSVN 0.7.0