Skip to content

πŸ§ͺ [testing improvement strcpy]#32

Closed
undivisible wants to merge 1 commit into
mainfrom
test-libc-strcpy-1882332888742230068
Closed

πŸ§ͺ [testing improvement strcpy]#32
undivisible wants to merge 1 commit into
mainfrom
test-libc-strcpy-1882332888742230068

Conversation

@undivisible

Copy link
Copy Markdown
Contributor

🎯 What: The missing tests for strcpy in kernel/libc.in:26 have been added to the comprehensive libc_selftest.
πŸ“Š Coverage: The test coverage now verifies that the return value points to the destination, string data correctly propagates, the NUL terminator is accurately placed (load8(s2 + 5) == 0), and there's a bounds check verifying the destination buffer is not written to past the NUL terminator (load8(s2 + 6) == 0x55).
✨ Result: Improved test coverage for kernel/libc.in catching potential regressions in strcpy memory bounds tracking or return pointer errors.


PR created automatically by Jules for task 1882332888742230068 started by @undivisible

Adds missing coverage for `strcpy` in `kernel/libc.in`. The added tests
verify that the return value matches the destination pointer, that the
copied string contains the expected NUL terminator, and that the buffer
is not overflowed past the NUL character (by using a pre-filled 0x55
pattern).

Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com>
@google-labs-jules

Copy link
Copy Markdown
Contributor

πŸ‘‹ Jules, reporting for duty! I'm here to lend a hand with this pull request.

When you start a review, I'll add a πŸ‘€ emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down.

I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job!

For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with @jules. You can find this option in the Pull Request section of your global Jules UI settings. You can always switch back!

New to Jules? Learn more at jules.google/docs.


For security, I will only act on instructions from the user who triggered this task.

@undivisible

Copy link
Copy Markdown
Contributor Author

Tests unsafe strcpy API removed by strlcpy merge (#28).

@undivisible

Copy link
Copy Markdown
Contributor Author

Closing as obsolete. Tests unsafe strcpy API removed by strlcpy merge (#28).

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant