Compare commits
No commits in common. "2ae359b04ae7038e0321c8f24c92888f58283684" and "ad66680e62838beeab861e91dfebe1c902ff6c20" have entirely different histories.
2ae359b04a
...
ad66680e62
@ -178,7 +178,6 @@
|
|||||||
* @lighty.md5(str)@: calculates the md5 checksum of the string @str@ (returns the digest as string in hexadecimal)
|
* @lighty.md5(str)@: calculates the md5 checksum of the string @str@ (returns the digest as string in hexadecimal)
|
||||||
* @lighty.sha1(str)@: calculates the sha1 checksum of the string @str@ (returns the digest as string in hexadecimal)
|
* @lighty.sha1(str)@: calculates the sha1 checksum of the string @str@ (returns the digest as string in hexadecimal)
|
||||||
* @lighty.sha256(str)@: calculates the sha256 checksum of the string @str@ (returns the digest as string in hexadecimal)
|
* @lighty.sha256(str)@: calculates the sha256 checksum of the string @str@ (returns the digest as string in hexadecimal)
|
||||||
* @lighty.path_simplify(str)@: return simplified path
|
|
||||||
]]></textile>
|
]]></textile>
|
||||||
|
|
||||||
<example>
|
<example>
|
||||||
@ -347,7 +346,7 @@
|
|||||||
|
|
||||||
<section title="Stat struct">
|
<section title="Stat struct">
|
||||||
<textile><![CDATA[
|
<textile><![CDATA[
|
||||||
Represents "struct stat". Most fields should be self explaining (@man 2 stat@ ("debian manpage":https://manpages.debian.org/stat.2.en.html) if you don't know them).
|
Represents "struct stat". Most fields should be self explaining (@man stat@ if you don't know them).
|
||||||
|
|
||||||
Fields:
|
Fields:
|
||||||
* @is_file@(ro): S_ISREG(mode)
|
* @is_file@(ro): S_ISREG(mode)
|
||||||
@ -365,7 +364,7 @@
|
|||||||
* @gid@(ro)
|
* @gid@(ro)
|
||||||
* @size@(ro)
|
* @size@(ro)
|
||||||
* @ino@(ro)
|
* @ino@(ro)
|
||||||
* @dev@(ro)
|
* @ino@(ro)
|
||||||
]]></textile>
|
]]></textile>
|
||||||
</section>
|
</section>
|
||||||
</section>
|
</section>
|
||||||
|
@ -358,6 +358,9 @@ void li_url_decode(GString *path) {
|
|||||||
* /blah/../foo gets /foo
|
* /blah/../foo gets /foo
|
||||||
* /abc/./xyz gets /abc/xyz
|
* /abc/./xyz gets /abc/xyz
|
||||||
* /abc//xyz gets /abc/xyz
|
* /abc//xyz gets /abc/xyz
|
||||||
|
*
|
||||||
|
* NOTE: src and dest can point to the same buffer, in which case
|
||||||
|
* the operation is performed in-place.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
void li_path_simplify(GString *path) {
|
void li_path_simplify(GString *path) {
|
||||||
@ -369,7 +372,7 @@ void li_path_simplify(GString *path) {
|
|||||||
if (path == NULL)
|
if (path == NULL)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
walk = start = out = slash = path->str;
|
walk = start = out = slash = path->str;
|
||||||
while (*walk == ' ') {
|
while (*walk == ' ') {
|
||||||
walk++;
|
walk++;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user