[Toybox] suggestion - dirtree_path

Ashwini Sharma ak.ashwini at gmail.com
Tue Jun 26 07:59:26 PDT 2012


Hi Rob,

 I have suggestion for function dirtree_path. In this function  '/' is
added in the path.
I think it can be modified to add the '/' only in case it not there, it
will avoid double "//" in the path.

It can be done by changing

*if(len) path[len++] = '/';*
to
||
V

*if(len)*
*   if(path[len -1] != '/') path[len++] = '/';*
*
*
regards,
Ashwini
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.landley.net/pipermail/toybox-landley.net/attachments/20120626/8638f89e/attachment-0003.htm>


More information about the Toybox mailing list