Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix compiler driver bug reading long dependency paths #26310

Closed
wants to merge 2 commits into from

Conversation

riftEmber
Copy link
Member

@riftEmber riftEmber commented Nov 22, 2024

Fix a bug causing the compiler driver to crash when working with dependency paths longer than 4096 characters.

Fixed by reading with std::getline which has no line length limit, rather than fgets which requires a (finite) buffer.

Resolves #26261.

[reviewer info placeholder]

Testing:

  • compiling program with >4096 character dependency paths
  • paratest
  • --no-compiler-driver paratest

@riftEmber riftEmber force-pushed the fix-driver-restore branch 2 times, most recently from c5e81a1 to 87c6100 Compare November 25, 2024 16:55
@riftEmber riftEmber marked this pull request as draft December 3, 2024 20:27
@riftEmber riftEmber force-pushed the fix-driver-restore branch 2 times, most recently from 3f865ff to 8e1327f Compare December 3, 2024 22:18
@riftEmber riftEmber force-pushed the fix-driver-restore branch 3 times, most recently from 3f2f707 to a5c4f94 Compare December 4, 2024 19:35
@riftEmber
Copy link
Member Author

Closing as this is an inadequate solution to the problem of using hardcoded limits in general (#8757) -- explanation at #26261 (comment).

Superseded by #26357 which includes this PR's changes.

@riftEmber riftEmber closed this Dec 4, 2024
@riftEmber riftEmber deleted the fix-driver-restore branch December 4, 2024 19:38
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.

[Bug]: long dependency paths can break compiler driver
1 participant