[PostGIS] #5661: Garden crash on ST_DFullyWithin

PostGIS trac at osgeo.org
Mon Jan 29 19:31:18 PST 2024


#5661: Garden crash on ST_DFullyWithin
---------------------+---------------------------
 Reporter:  robe     |      Owner:  pramsey
     Type:  defect   |     Status:  new
 Priority:  blocker  |  Milestone:  PostGIS 3.5.0
Component:  postgis  |    Version:  master
 Keywords:           |
---------------------+---------------------------
 {{{
 SELECT
 ST_DFullyWithin('0102000020E610000005000000000000000000F07F000000000000F07F000000000000F07F000000000000F07F000000000000F07F000000000000F07F000000000000F07F000000000000F07F000000000000F07F000000000000F07F'::geometry,
 ST_GeomFromText('POINT(-11.1111111 40)',4326),100);
 }}}

 my backtrace looks like this.


 {{{
 #0  0x0000000064d25eb2 in
 geos::operation::buffer::OffsetSegmentGenerator::createCircle(geos::geom::Coordinate
 const&, double) ()
    from C:\ming64gcc81\projects\geos\rel-3.12.1w64gcc81\bin\libgeos.dll
 #1  0x0000000064d2041f in
 geos::operation::buffer::OffsetCurveBuilder::getLineCurve(geos::geom::CoordinateSequence
 const*, double, std::vector<geos::geom::CoordinateSequence*,
 std::allocator<geos::geom::CoordinateSequence*> >&) ()
    from C:\ming64gcc81\projects\geos\rel-3.12.1w64gcc81\bin\libgeos.dll
 #2  0x0000000064d15a98 in
 geos::operation::buffer::BufferCurveSetBuilder::addLineString(geos::geom::LineString
 const*) ()
    from C:\ming64gcc81\projects\geos\rel-3.12.1w64gcc81\bin\libgeos.dll
 #3  0x0000000064d15c6d in
 geos::operation::buffer::BufferCurveSetBuilder::add(geos::geom::Geometry
 const&) ()
    from C:\ming64gcc81\projects\geos\rel-3.12.1w64gcc81\bin\libgeos.dll
 #4  0x0000000064d15db1 in
 geos::operation::buffer::BufferCurveSetBuilder::getCurves() () from
 C:\ming64gcc81\projects\geos\rel-3.12.1w64gcc81\bin\libgeos.dll
 #5  0x0000000064d11d0d in
 geos::operation::buffer::BufferBuilder::buffer(geos::geom::Geometry
 const*, double) ()
    from C:\ming64gcc81\projects\geos\rel-3.12.1w64gcc81\bin\libgeos.dll
 #6  0x0000000064d16c29 in
 geos::operation::buffer::BufferOp::bufferOriginalPrecision() ()
    from C:\ming64gcc81\projects\geos\rel-3.12.1w64gcc81\bin\libgeos.dll
 #7  0x0000000064d17365 in
 geos::operation::buffer::BufferOp::getResultGeometry(double) ()
    from C:\ming64gcc81\projects\geos\rel-3.12.1w64gcc81\bin\libgeos.dll
 #8  0x0000000064d17709 in
 geos::operation::buffer::BufferOp::bufferOp(geos::geom::Geometry const*,
 double, int, int) ()
    from C:\ming64gcc81\projects\geos\rel-3.12.1w64gcc81\bin\libgeos.dll
 #9  0x0000000064c80fd5 in geos::geom::Geometry::buffer(double, int) const
 ()
    from C:\ming64gcc81\projects\geos\rel-3.12.1w64gcc81\bin\libgeos.dll
 #10 0x00000000053e817b in GEOSBuffer_r ()
    from C:\ming64gcc81\projects\geos\rel-3.12.1w64gcc81\bin\libgeos_c.dll
 #11 0x000000006c55a393 in LWGEOM_dfullywithin (fcinfo=0x84dd448)
     at lwgeom_geos.c:3556
 #12 0x0000000000615f2e in ExecInterpExpr (state=0x84dd368,
     econtext=0x84dd5c8, isnull=<optimized out>) at execExprInterp.c:758
 #13 0x000000000071a651 in ExecEvalExprSwitchContext (isNull=0x52deb8c,
     econtext=<optimized out>, state=0x84dd368)
     at ../../../../src/include/executor/executor.h:355
 #14 evaluate_expr (expr=<optimized out>, result_type=result_type at entry=16,
     result_typmod=result_typmod at entry=-1,
     result_collation=result_collation at entry=0) at clauses.c:4902
 #15 0x000000000071c138 in evaluate_function (context=0x52df030,
     func_tuple=0x84720a8, funcvariadic=false, args=0x84c7000,
 input_collid=0,
     result_collid=0, result_typmod=-1, result_type=16, funcid=122240)
     at clauses.c:4409
 #16 simplify_function (funcid=122240, result_type=16, result_typmod=-1,
     result_collid=result_collid at entry=0,
 input_collid=input_collid at entry=0,
     args_p=args_p at entry=0x52ded70, funcvariadic=funcvariadic at entry=false,
     process_args=process_args at entry=true,
     allow_non_const=allow_non_const at entry=true,
     context=context at entry=0x52df030) at clauses.c:3997
 #17 0x000000000071a9c5 in eval_const_expressions_mutator (node=0x84c6888,
     context=0x52df030) at clauses.c:2503
 #18 0x0000000000692eb6 in expression_tree_mutator_impl (
     node=node at entry=0x84c68d8,
     mutator=mutator at entry=0x71a6f0 <eval_const_expressions_mutator>,
     context=context at entry=0x52df030) at nodeFuncs.c:3516
 #19 0x000000000071a945 in eval_const_expressions_mutator (node=0x84c68d8,
     context=0x52df030) at clauses.c:3616
 #20 0x0000000000693604 in expression_tree_mutator_impl (
     node=node at entry=0x84c6928,
     mutator=mutator at entry=0x71a6f0 <eval_const_expressions_mutator>,
     context=context at entry=0x52df030) at nodeFuncs.c:3383
 #21 0x000000000071a945 in eval_const_expressions_mutator (node=0x84c6928,
     context=context at entry=0x52df030) at clauses.c:3616
 #22 0x000000000071bfa4 in eval_const_expressions
 (root=root at entry=0x84c6a18,
     node=<optimized out>) at clauses.c:2183
 #23 0x00000000006fd52e in preprocess_expression
 (root=root at entry=0x84c6a18,
     expr=<optimized out>, kind=kind at entry=1) at planner.c:1144
 #24 0x0000000000706167 in subquery_planner (glob=glob at entry=0x7b541a0,
     parse=<optimized out>, parse at entry=0x7b542b0,
     parent_root=parent_root at entry=0x0,
 hasRecursion=hasRecursion at entry=false,
     tuple_fraction=tuple_fraction at entry=0) at planner.c:810
 #25 0x00000000007069cf in standard_planner (parse=0x7b542b0,
     query_string=<optimized out>, cursorOptions=2048,
     boundParams=<optimized out>) at planner.c:413
 #26 0x00000000007efe3a in pg_plan_query (querytree=0x7b542b0,
     query_string=0x7b52e38 "SELECT ST_DFullyWithin('0102000020E610000005",
 '0' <repeats 18 times>, "F07F", '0' <repeats 12 times>, "F07F", '0'
 <repeats 12 times>, "F07F", '0' <repeats 12 times>, "F07F", '0' <repeats
 12 times>, "F07F", '0' <repeats 12 times>, "F07F", '0' <repeats 12 times>,
 "F07F", '0' <repeats 12 times>, "F07F", '0' <repeats 12 times>,
 "F07F000000"..., cursorOptions=2048,
     boundParams=0x0) at postgres.c:904
 #27 0x00000000007eff41 in pg_plan_queries (querytrees=0x84c69c8,
     query_string=query_string at entry=0x7b52e38 "SELECT
 ST_DFullyWithin('0102000020E610000005", '0' <repeats 18 times>, "F07F",
 '0' <repeats 12 times>, "F07F", '0' <repeats 12 times>, "F07F", '0'
 <repeats 12 times>, "F07F", '0' <repeats 12 times>, "F07F", '0' <repeats
 12 times>, "F07F", '0' <repeats 12 times>, "F07F", '0' <repeats 12 times>,
 "F07F", '0' <repeats 12 times>, "F07F000000"...,
     cursorOptions=cursorOptions at entry=2048,
 boundParams=boundParams at entry=0x0)
     at postgres.c:996
 #28 0x00000000007f02c5 in exec_simple_query (
     query_string=0x7b52e38 "SELECT ST_DFullyWithin('0102000020E610000005",
 '0' <repeats 18 times>, "F07F", '0' <repeats 12 times>, "F07F", '0'
 <repeats 12 times>, "F07F", '0' <repeats 12 times>, "F07F", '0' <repeats
 12 times>, "F07F", '0' <repeats 12 times>, "F07F", '0' <repeats 12 times>,
 "F07F", '0' <repeats 12 times>, "F07F", '0' <repeats 12 times>,
 "F07F000000"...) at postgres.c:1193
 #29 0x00000000007f4f05 in PostgresMain (dbname=0x7ac8758
 "postgis_garden_35",
     username=0x62e8fb8 "postgres") at postgres.c:4637
 #30 0x00000000007523f2 in BackendRun (port=0x52df7c0, port=0x52df7c0)
     at postmaster.c:4464
 #31 SubPostmasterMain (argc=argc at entry=3, argv=argv at entry=0x62e6f90)
     at postmaster.c:4960
 #32 0x00000000009b3944 in main (argc=3, argv=0x62e6f90) at main.c:190

 }}}


  I know my geos is old, have to figure out why I'm compiling with this old
 version, but berrie64 is complaining about the same thing and is running
 with GEOS 3.13 (master), so assume the problem exists regardless of geos
 version
-- 
Ticket URL: <https://trac.osgeo.org/postgis/ticket/5661>
PostGIS <http://trac.osgeo.org/postgis/>
The PostGIS Trac is used for bug, enhancement & task tracking, a user and developer wiki, and a view into the subversion code repository of PostGIS project.


More information about the postgis-tickets mailing list