Extract base path from a pathname in C

后端 未结 8 1843
南笙
南笙 2020-12-30 14:21

Question

How do you extract the base path from pathname in C?

Are there any functions built into the C language or the C-Runtime L

8条回答
  •  暗喜
    暗喜 (楼主)
    2020-12-30 15:08

    WinAPI (shlwapi) PathRemoveFileSpec should do all of that with the exception of .\file which would come back as .

提交回复
热议问题