* fix in the net.`$` to print zeros that are not in the compressed group * Update lib/pure/net.nim Co-authored-by: Andreas Rumpf <rumpf_a@web.de> * Update net.nim Co-authored-by: Andreas Rumpf <rumpf_a@web.de>
This commit is contained in:
parent
64eb62889a
commit
7252a50fef
1 changed files with 4 additions and 0 deletions
|
|
@ -1827,6 +1827,10 @@ proc `$`*(address: IpAddress): string =
|
|||
result.add(chr(uint16(ord('a'))+val-0xA))
|
||||
afterLeadingZeros = true
|
||||
mask = mask shr 4
|
||||
|
||||
if not afterLeadingZeros:
|
||||
result.add '0'
|
||||
|
||||
printedLastGroup = true
|
||||
|
||||
proc dial*(address: string, port: Port,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue