Skip to content

文件分割算法有误 #2

Description

@duxingzhe

文件分割算法中,判断文件是否能完整分割的判断应该是file_size%fileNum==0,因为如果if(0),0的结果是假。
还有,如果文件不能完整分割,应该是先算出分割的数量为file_part=file_size/fileNum,然后求出剩余的部分为last_file_part_size=file_size%fileNum,于是第一个循环应该是从0-fileNum-1。才对。

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions