ports/151927: databases/mysql55-server: crash on startup as MAX_DEFAULT_DIRS too small

Bartosz Fabianowski freebsd at chillt.de
Wed Nov 3 22:40:08 UTC 2010


>Number:         151927
>Category:       ports
>Synopsis:       databases/mysql55-server: crash on startup as MAX_DEFAULT_DIRS too small
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Nov 03 22:40:08 UTC 2010
>Closed-Date:
>Last-Modified:
>Originator:     Bartosz Fabianowski
>Release:        8.1-STABLE
>Organization:
>Environment:
FreeBSD taiko.lan 8.1-STABLE FreeBSD 8.1-STABLE #0: Thu Sep  9 00:16:43 IST 2010     root at taiko.lan:/usr/obj/usr/src/sys/TAIKO  amd64
>Description:
The file mysys/default.c contains a method init_default_directories() that populates a list of directories to search for options. The maximal list size is given by MAX_DEFAULT_DIRS, set in the same file to 6.

A patch included in the FreeBSD port adds an extra directory but does not bump MAX_DEFAULT_DIRS from 6 to 7.

Since this issue is created by the FreeBSD port in the first place, it is not an upstream bug.
>How-To-Repeat:
I spotted this with an embedded MySQL server. I expect it will happen with the non-embedded server as well: Set DEFAULT_HOME_ENV in the environment, then launch the server. It will attempt to add seven directories to the list and abort.

>Fix:
Add a patch in the port that increases MAX_DEFAULT_DIRS by one.

>Release-Note:
>Audit-Trail:
>Unformatted:



More information about the freebsd-ports-bugs mailing list