URL: <http://gna.org/bugs/?17508>
Summary: Loading savegames for Britain/Europe scenarios gives many errors and server segfault Project: Freeciv Submitted by: jtn Submitted on: Sun Jan 16 22:43:19 2011 Category: None Severity: 4 - Important Priority: 5 - Normal Status: None Assigned to: None Originator Email: Open/Closed: Open Release: Discussion Lock: Any Operating System: None Planned Release: 2.3.0 _______________________________________________________ Details: Split out from bug #17459, where roywephy originally reported it: Trunk and S2_3 (r18960), and reportedly trunk r18867, give lots of errors and crash when loading savegames created from the bundled british-isles-85x80-v2.80 (73x81) and europe-200x100-v2 (177x100) scenarios. roywephy suggests <https://gna.org/bugs/?17459#comment2> that this is correlated with an odd width (and/or possibly height). I notice that I not allowed to manually set odd width or height via xsize/ysize server settings ("The map width must be an even value"), but I don't know why that is. If the map width/height is required to be even for some reason, do we need to tweak the bundled scenarios, and possibly add assertions/errors on scenario and savefile load to catch odd widths/heights? Are there any valid savegames/scenarios that we'd refuse to load as a result? (I note that the relevant scenarios have the same proportions on S2_2, so the answer is probably yes.) Here are the errors and backtrace I get for S2_3 r18958 on the attached europe.sav.bz2. Encodings: Data=UTF-8, Local=UTF-8, Internal=UTF-8 This is the server for Freeciv version 2.3.0-beta1+ (beta version) You can learn a lot about Freeciv at http://www.freeciv.org/ THIS IS A BETA VERSION Freeciv 2.3.0 will be released in March, at http://www.freeciv.org/ 2: Loading rulesets. 2: AI*1 has been added as Easy level AI-controlled player. 2: AI*2 has been added as Easy level AI-controlled player. 2: AI*3 has been added as Easy level AI-controlled player. 2: AI*4 has been added as Easy level AI-controlled player. 2: AI*5 has been added as Easy level AI-controlled player. 1: Error restoring 'xsize': The map width must be an even value. 1: Error restoring 'generator': You cannot disable the map generator. 1: Error restoring 'onsetbarbs': Value out of range: -2000 (min: 0; max: 32767). 2: Removing player AI*1. 2: Removing player AI*2. 2: Removing player AI*3. 2: Removing player AI*4. 2: Removing player AI*5. 1: Saved game contains incomplete map data. This can happen with old saved games, or it may indicate an invalid saved game file. Proceed at your own risk. 1: Start position native coordinates (66, 29) do not exist in this map. Skipping ... 1: Start position native coordinates (78, 55) do not exist in this map. Skipping... 1: Start position native coordinates (88, 33) do not exist in this map. Skipping... 1: Start position native coordinates (72, 54) do not exist in this map. Skipping... 1: Start position native coordinates (120, 24) do not exist in this map. Skipping... 1: Start position native coordinates (76, 50) do not exist in this map. Skipping... 1: Start position native coordinates (88, 67) do not exist in this map. Skipping... 1: Start position native coordinates (113, 44) do not exist in this map. Skipping... 1: Start position native coordinates (81, 70) do not exist in this map. Skipping... 1: Start position native coordinates (73, 40) do not exist in this map. Skipping... 1: Start position native coordinates (109, 59) do not exist in this map. Skipping... 1: Start position native coordinates (97, 65) do not exist in this map. Skipping... 1: Start position native coordinates (134, 95) do not exist in this map. Skipping... 1: Start position native coordinates (97, 20) do not exist in this map. Skipping... 1: Start position native coordinates (77, 62) do not exist in this map. Skipping... 1: Start position native coordinates (101, 87) do not exist in this map. Skipping... 1: Start position native coordinates (155, 84) do not exist in this map. Skipping... 1: Start position native coordinates (121, 80) do not exist in this map. Skipping... 1: Start position native coordinates (89, 42) do not exist in this map. Skipping... 1: Start position native coordinates (94, 26) do not exist in this map. Skipping... 1: Start position native coordinates (85, 53) do not exist in this map. Skipping... 1: Start position native coordinates (86, 58) do not exist in this map. Skipping... 1: Start position native coordinates (80, 67) do not exist in this map. Skipping... 1: Start position native coordinates (71, 76) do not exist in this map. Skipping... 1: Start position native coordinates (92, 13) do not exist in this map. Skipping... 1: Start position native coordinates (78, 20) do not exist in this map. Skipping... 1: Saved game contains incomplete map data. This can happen with old saved games, or it may indicate an invalid saved game file. Proceed at your own risk. 1: last message repeated 2 times 1: last message repeated 2 times (total 4 repeats) 1: last message repeated 4 times (total 8 repeats) 1: last message repeated 4 times (total 12 repeats) 2: Hannibal Barca has been added as human player. 1: player1.u0 invalid tile (80, 70) 1: Error loading unit 0 of player 1. 1: Failure loading savegame! 1: in terrain_index() [terrain.c::129]: assertion 'pterrain' failed. 1: Please report this message at http://gna.org/projects/freeciv/ 1: in load_command() [stdinhand.c::3554]: assertion 'terrain_index(pterrain) >= 0 && terrain_index(pterrain) < terrain_count()' failed. Segmentation fault (core dumped) Backtrace: #0 0x00007f71e65b735e in vfprintf () from /lib/libc.so.6 No symbol table info available. #1 0x00007f71e666b760 in __vsnprintf_chk () from /lib/libc.so.6 No symbol table info available. #2 0x0000000000596370 in vsnprintf ( str=0xa33520 "( 0, 0) at \"s message at http://gna.org/projects/freeciv/", n=512, format=0x6 <Address 0x6 out of bounds>, ap=0x40) at /usr/include/bits/stdio2.h:78 No locals. #3 fc_vsnprintf ( str=0xa33520 "( 0, 0) at \"s message at http://gna.org/projects/freeciv/", n=512, format=0x6 <Address 0x6 out of bounds>, ap=0x40) at support.c:691 r = <value optimised out> __FUNCTION__ = "fc_vsnprintf" #4 0x0000000000583faa in vdo_log (file=<value optimised out>, function=0x5c75d1 "load_command", line=3554, print_from_where=false, level=LOG_ERROR, message=0x5e22d8 "(%4d, %4d) at \"%s\"", args=0x7fff1844aef0) at log.c:362 bufbuf = { "assertion 'terrain_index(pterrain) >= 0 && terrain_index(pterrain) < terrain_count()' failed.\000ate an invalid saved game file. Proceed at your own risk.", '\000' <repeats 360 times>, "( 0, 0) at \"s message at http://gna.org/projects/freeciv/\000ld saved games, or it may indicate an invalid saved game file. Proceed at your own risk.", '\000' <repeats 360 times>} bufbuf1 = true repeated = 0 next = 2 prev = 0 prev_level = LOG_ERROR recursive = true buf = "\360\362\350\000\000\000\000\000u\320Y\346q\177", '\000' <repeats 26 times>"\210, \256D\030\377\177\000\000\360\362\350\000\000\000\000\000\001\000\000\000\000\000\000\000\020\374\350\000\000\000\000\000qeY\000\000\000\000\000 \000\000\000 \\^\000\000\306ۉuT\024\065\000\255D\030\377\177\000\000\234\316I\000\000\000\000\000\001\000\000\000\000\000\000\000\000\256D\030\377\177\000\000\n\000\000\000\000\000\000\000\210\256D\030\377\177\000\000X\034\\\000\000\000\000\000\360\362\350\000\000\000\000\000\006\000\000\000\000\000\000\000\220\372\350\000\000\000\000\000\300\256D\030\377\177\000\000\064\313Y\346q\177\000\000C\000_GB.UTF-8\000q\177\000\000\b\000\000\000\000\000\000\000\320\310Y\346q\177\000\000LC_MESSAGES/freeciv.mo", '\000' <repeats 19 times>"\306"... fs = <value optimised out> #5 0x0000000000584490 in fc_assert_fail (file=0x5c3ca2 "stdinhand.c", function=0x5c75d1 "load_command", line=3554, assertion=<value optimised out>, message=0x5e22d8 "(%4d, %4d) at \"%s\"") at log.c:466 args = {{gp_offset = 48, fp_offset = 48, overflow_arg_area = 0x7fff1844b000, reg_save_area = 0x7fff1844af10}} level = LOG_ERROR #6 0x0000000000496223 in check_specials (file=<value optimised out>, function=<value optimised out>, line=3554) at sanitycheck.c:94 ptile_city = 0x0 pterrain = 0x0 special = <value optimised out> ptile = 0x1f4f270 ptile_index = 0 #7 real_sanity_check (file=<value optimised out>, function=<value optimised out>, line=3554) at sanitycheck.c:562 No locals. #8 0x000000000041408a in load_command (caller=<value optimised out>, filename=<value optimised out>, check=<value optimised out>) at stdinhand.c:3554 loadtimer = 0x16d5330 uloadtimer = 0x16d5370 file = <value optimised out> arg = "/home/jtn/.freeciv/saves/europe.sav.bz2", '\000' <repeats 49 times>, "85=\347q\177\000\000/\000\000\000\000\000\000\000-W\036\347q\177\000\000\000\000\000\000\000\000\000\000\270\071=\347q\177\000\000\020\000\000\000\000\000\000\000\001", '\000' <repeats 23 times>, "`\303D\030\377\177\000\000\000\304D\030\377\177\000\000\000\060=\347q\177\000\000\001", '\000' <repeats 15 times>"\365, \v\036\347q\177\000\000\000\000\000\000\000\000\000\000M\227\036\347q\177\000\000\000\000\000\000\000\000\000\000ix\022\346q\177\000\000\000\000\000\000\000\000\000\000\022\"\036\347q\177", '\000' <repeats 19 times>"\241, \062\346q\177\000\000\000\241\062\346q"... __FUNCTION__ = "load_command" #9 0x000000000040c3e6 in srv_prepare () at srv_main.c:2251 __FUNCTION__ = "srv_prepare" #10 0x000000000040c504 in srv_main () at srv_main.c:2518 __FUNCTION__ = "srv_main" #11 0x0000000000404137 in main (argc=<value optimised out>, argv=0x7fff1844d338) at civserver.c:375 inx = 5 showhelp = false showvers = false option = 0xe8f480 "/usr/local/share/locale/en_GB/LC_MESSAGES/freeciv.mo" __FUNCTION__ = "main" _______________________________________________________ File Attachments: ------------------------------------------------------- Date: Sun Jan 16 22:43:19 2011 Name: europe.sav.bz2 Size: 24kB By: jtn Scenario savegames which give errors/segfaults with S2_3 r18958 <http://gna.org/bugs/download.php?file_id=11925> ------------------------------------------------------- Date: Sun Jan 16 22:43:19 2011 Name: britain.sav.bz2 Size: 13kB By: jtn Scenario savegames which give errors/segfaults with S2_3 r18958 <http://gna.org/bugs/download.php?file_id=11926> _______________________________________________________ Reply to this item at: <http://gna.org/bugs/?17508> _______________________________________________ Message sent via/by Gna! http://gna.org/ _______________________________________________ Freeciv-dev mailing list Freeciv-dev@gna.org https://mail.gna.org/listinfo/freeciv-dev