recursive file search

前端 未结 6 952
爱一瞬间的悲伤
爱一瞬间的悲伤 2021-01-06 13:49

I\'m trying to figure out how to work this thing out .. For some reason, it ends at a certain point.. I\'m not very good at recursion and I\'m sure the problem lies somewher

6条回答
  •  谎友^
    谎友^ (楼主)
    2021-01-06 14:24

    You are changing the value of your local wrkdir variable:

    wrkdir = wrkdir + L"\\" + file_data.cFileName;
    find_files( wrkdir );
    

    I think you have to call find_files there like this:

    find_files( wrkdir + L"\\" + file_data.cFileName );
    

    and not change the value of wrkdir.

提交回复
热议问题