Skip to content

Misleading command code comment in `FM_ChildFileInfoCmd #130

@moonlight83340

Description

@moonlight83340

Description

In the function FM_ChildFileInfoCmd, the comment describing the command arguments contains an incorrect command code reference:

** CmdArgs->CommandCode = FM_GET_DIR_LIST_FILE_CC

/*
** Command argument usage for this command:
**
**  CmdArgs->CommandCode   = FM_GET_DIR_LIST_FILE_CC
**  CmdArgs->Source1       = name of directory or file
**  CmdArgs->FileInfoState = state of directory or file
**  CmdArgs->FileInfoSize  = file size, else zero
**  CmdArgs->FileInfoTime  = last modify time
*/

However, this function handles the Get File Info command, and the correct command code should be:

FM_GET_FILE_INFO_CC

Issue

The current comment is misleading because:

  • FM_GET_DIR_LIST_FILE_CC refers to a different command (directory listing context)
  • This can confuse developers trying to understand or maintain the code
  • It may lead to incorrect assumptions when tracing command handling

Suggested Fix

Update the comment to:

CmdArgs->CommandCode   = FM_GET_FILE_INFO_CC

Impact

This is a documentation/comment issue only and does not affect runtime behavior.

Metadata

Metadata

Assignees

No one assigned
    No fields configured for Feature.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions