Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Segfault when using ttf symbols with symbolscalednom and minsize=0 #5086

Merged
merged 1 commit into from Apr 2, 2015
Merged

Segfault when using ttf symbols with symbolscalednom and minsize=0 #5086

merged 1 commit into from Apr 2, 2015

Conversation

tbonfort
Copy link
Member

@tbonfort tbonfort commented Apr 2, 2015

MapServer will crash at very small scales, when a ttf symbol is used together with symbolscalednom, but without minsize, which is default 0.

MAP
        SIZE 1000 500
        EXTENT -90 -90 90 90
        PROJECTION
                "init=epsg:4326"
        END

        FONTSET 'glyph.fonts'

        SYMBOL
                NAME "test"
                TYPE TRUETYPE
                FONT "arial"
                CHARACTER 'a'
        END

        LAYER
                TYPE LINE
                STATUS DEFAULT

                FEATURE
                        POINTS
                                0 0
                                20 20
                        END
                END

                NAME 'ttflayer'
                STATUS DEFAULT
                PROJECTION
                        'init=epsg:4326'
                END

                SYMBOLSCALEDENOM 100

                CLASS
                        STYLE
                                SYMBOL "test"
                                WIDTH 2
#                               MINSIZE 1
                        END
                END
        END
END

@mkofahl mkofahl added the Bug label Apr 2, 2015
@mkofahl mkofahl added this to the 7.0 Release milestone Apr 2, 2015
@tbonfort tbonfort self-assigned this Apr 2, 2015
@tbonfort
Copy link
Member

tbonfort commented Apr 2, 2015

cannot reproduce ...

@mkofahl
Copy link
Contributor Author

mkofahl commented Apr 2, 2015

Compiled from github master again, changed arial.ttf to Vera.ttf from msautotest, still segfaulting when running ./shp2img -m glyph.map.

@tbonfort
Copy link
Member

tbonfort commented Apr 2, 2015

my bad, I was testing with 6.4. Can reproduce with 7.0-beta1

@tbonfort
Copy link
Member

tbonfort commented Apr 2, 2015

Not sure what we should be doing in this case, as we're requesting a ttf symbol that is smaller than a pixel. Should we force to size=1 or size=0 (i.e. render nothing)?

@tbonfort tbonfort merged commit 29bbefa into MapServer:branch-7-0 Apr 2, 2015
@mkofahl
Copy link
Contributor Author

mkofahl commented Apr 2, 2015

Thank you for fixing this @tbonfort

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants