Skip to content

Fix #344, Consistent directory entry size limit#423

Merged
astrogeco merged 2 commits intonasa:integration-candidatefrom
skliper:fix344-dirent-name-size
Apr 28, 2020
Merged

Fix #344, Consistent directory entry size limit#423
astrogeco merged 2 commits intonasa:integration-candidatefrom
skliper:fix344-dirent-name-size

Conversation

@skliper
Copy link
Contributor

@skliper skliper commented Apr 17, 2020

Describe the contribution
Changes FileName in os_dirent_t from OS_MAX_PATH_LEN to OS_MAX_FILE_NAME,
and moves OS_check_name_length into OS_TranslatePath so it is
consistantly applied everywhere. Also fixes the length checks in
OS_check_name_length to account for terminating null.

Unit tests updated to match new directory name limit.
Fix #344

Note - since this was merged with the #262 fix, this will also resolve that issue.

Testing performed
Steps taken to test the contribution:

  1. CI - https://travis-ci.com/github/skliper/cFS/builds/160789041

Expected behavior changes
Individual directory names now limited to OS_MAX_FILE_NAME

System(s) tested on

  • Hardware: cFS Dev Server 3
  • OS: Ubuntu 18.04
  • Versions: bundle + this branch

Additional context
Note it's based on #421 to avoid conflicts and help with IC merge.

Third party code
None

Contributor Info - All information REQUIRED for consideration of pull request
Jacob Hageman - NASA/GSFC

@skliper skliper added the CCB:Ready Pull request is ready for discussion at the Configuration Control Board (CCB) label Apr 17, 2020
@skliper skliper force-pushed the fix344-dirent-name-size branch from 70c3e7f to e8a1cfe Compare April 22, 2020 00:16
@skliper
Copy link
Contributor Author

skliper commented Apr 22, 2020

Rebased on the OS_FS deprecation commit to resolve conflicts. Also fixed all the coverage test errors from the rebase on master (didn't previously run the coverage tests). Confirmed 100% coverage on filesys.

@astrogeco
Copy link
Contributor

CCB 20200422 - APPROVED

@skliper skliper added CCB - 20200422 CCB:Approved Indicates code review and approval by community CCB and removed CCB:Ready Pull request is ready for discussion at the Configuration Control Board (CCB) labels Apr 22, 2020
@astrogeco astrogeco changed the base branch from master to integration-candidate April 27, 2020 23:00
@astrogeco
Copy link
Contributor

@skliper check conflicts, might need to work around #427

dmknutsen and others added 2 commits April 28, 2020 13:19
Changes FileName in os_dirent_t from OS_MAX_PATH_LEN to OS_MAX_FILE_NAME,
and moves OS_check_name_length into OS_TranslatePath so it is
consistantly applied everywhere. Also fixes the length checks in
OS_check_name_length to account for terminating null.

Unit tests updated to match new directory name limit.  Coverage
tests updated to match simplified logic.
@skliper skliper force-pushed the fix344-dirent-name-size branch from e8a1cfe to 3fdd398 Compare April 28, 2020 17:19
@skliper
Copy link
Contributor Author

skliper commented Apr 28, 2020

@astrogeco try this... resolved conflicts

@astrogeco astrogeco merged commit a67ad31 into nasa:integration-candidate Apr 28, 2020
@skliper skliper linked an issue Apr 28, 2020 that may be closed by this pull request
@skliper skliper added this to the 5.1.0 milestone Jun 1, 2020
@skliper skliper deleted the fix344-dirent-name-size branch February 1, 2021 21:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CCB:Approved Indicates code review and approval by community CCB

Projects

None yet

Development

Successfully merging this pull request may close these issues.

os_dirent_t.FileName uses OS_MAX_PATH_LEN for array size Move OS_FS_ERR_* defines to common os error definitions

3 participants