Hi, here is the modified patch of EdgeCommand. As written before I changed the implementation of the function CMD_EdgeCommand and the man page entry. The function duplicateString has been removed the existing function safestrdup is used instead. In the CMD_EdgeCommand function there is no parsing done. The new introduced function ParseDirectionArgument(..) is used. This function can distinguish the following directions strings:
... char *optlist[] = { "N", "North", "Top", "Up", "E", "East", "Right", "Right", "S", "South", "Bottom", "Down", "W", "West", "Left", "Left", "NE", "NorthEast", "TopRight", "UpRight", "SE", "SouthEast", "BottomRight", "DownRight", "SW", "SouthWest", "BottomLeft", "DownLeft", "NW", "NorthWest", "TopLeft", "UpLeft", NULL }; ... In the man page I have only documented the directions "North", "Top", "West", "Left", "South", "Bottom", "Right" and "East" but not "N", "E", "S", "W", "Up", and "Down". The later are not documented but could be used. I did not want to produce to much overhead that's why it is not documented. Maybe later there will be a section in the man page about directions in general. Any other command which used the ParseDirectionArgument(..) function could just refer to this section. I have tested the reimplemented function again - no crashes or seg faults. Uwe -- +---------------------------------------------- | Uwe Pross | mail : mailto:[EMAIL PROTECTED] | www : http://www.tu-chemnitz.de/~uwp +---------------------------------------------- Have a nice day ;-). -----------------------------------------------
patch.EdgeCommand.gz
Description: application/gunzip