Skip to content

Commit 3de84a6

Browse files
committedAug 26, 2015
[GRASS] always alloc more spece for Map_info structure
1 parent 40828e8 commit 3de84a6

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed
 

‎src/providers/grass/qgsgrass.cpp

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2447,12 +2447,13 @@ struct Map_info *QgsGrass::vectNewMapStruct()
24472447
// In OSGeo4W there is GRASS compiled by MinGW while QGIS compiled by MSVC, the compilers
24482448
// may have different sizes of types, see issue #13002. Because there is no Vect_new_map_struct (GRASS 7.0.0, July 2015)
24492449
// the structure is allocated here using doubled (should be enough) space.
2450+
2451+
// The same problem was also reported for QGIS 2.11-master compiled on Xubuntu 14.04 LTS
2452+
// using GRASS 7.0.1-2~ubuntu14.04.1 from https://launchpad.net/~grass/+archive/ubuntu/grass-stable
2453+
// -> allocate more space on all systems
2454+
24502455
// TODO: replace by Vect_new_map_struct once it appears in GRASS
2451-
#ifdef Q_OS_WIN
24522456
return ( struct Map_info* ) qgsMalloc( 2*sizeof( struct Map_info ) );
2453-
#else
2454-
return ( struct Map_info* ) qgsMalloc( sizeof( struct Map_info ) );
2455-
#endif
24562457
}
24572458

24582459
void QgsGrass::vectDestroyMapStruct( struct Map_info *map )

0 commit comments

Comments
 (0)
Please sign in to comment.