From 8fb2b9a0a505a9051bac04ab0163b20db95b86fb Mon Sep 17 00:00:00 2001 From: bptato Date: Tue, 25 Jan 2022 16:40:55 +0100 Subject: Fix some path bugs and misc. warnings --- src/utils/twtstr.nim | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'src/utils/twtstr.nim') diff --git a/src/utils/twtstr.nim b/src/utils/twtstr.nim index e2d06535..a0dd1b3f 100644 --- a/src/utils/twtstr.nim +++ b/src/utils/twtstr.nim @@ -128,9 +128,6 @@ func toAsciiLower*(str: string): string = for i in 0..str.high: result[i] = str[i].tolower() -func getrune(s: string): Rune = - return s.toRunes()[0] - func genHexCharMap(): seq[int] = for i in 0..255: case chr(i) @@ -565,7 +562,7 @@ proc expandPath*(path: string): string = while path[i] != '/': usr &= path[i] inc i - let p = getpwnam(usr) + let p = getpwnam(cstring(usr)) if p != nil: result = $p.pw_dir / path.substr(i) -- cgit 1.4.1-2-gfad0