backtrace:
Code: |
Thread 1 "div-LINUX" received signal SIGSEGV, Segmentation fault.
0x00005555555c88b6 in map_editpoint () at src/divmap3d.c:2290
2290 my_map->points[edit_point]->x=x;
(gdb) bt
#0 0x00005555555c88b6 in map_editpoint () at src/divmap3d.c:2290
#1 0x00005555555cba45 in MapperCreator2 () at src/divmap3d.c:677
|
edit_point:
Code: |
(gdb) p edit_point
$4 = -1
|
Perdón, voy a escribir en español.
Entonces se vé que edit_point es igual a -1 y esto causa el SIGSEGV.
Posible fix así sin pensarlo mucho xD
Code: |
diff --git a/src/divmap3d.c b/src/divmap3d.c
index ad49752..1937726 100644
--- a/src/divmap3d.c
+++ b/src/divmap3d.c
@@ -2284,7 +2284,7 @@ void map_editpoint()
}
}
- if (mouse_b&2 && old_but2==0) {
+ if (edit_point != -1 && mouse_b&2 && old_but2==0) {
if(mouse_b&1) MouseFocus=0;
old_but2=1; old_but1=0;
my_map->points[edit_point]->x=x;
~
|
|