Skip to content

NULL check environ before dereference - #469

Closed
systems-assistant[bot] wants to merge 2 commits into
developfrom
import/develop/dusan-exostellar_clr/environ_null_check
Closed

systems-assistant[bot] wants to merge 2 commits into
developfrom
import/develop/dusan-exostellar_clr/environ_null_check

Conversation

@systems-assistant

Copy link
Copy Markdown
Contributor

Associated JIRA ticket number/Github issue number

Closes ROCm/clr#164

What type of PR is this? (check all applicable)

  • Refactor
  • Feature
  • Bug Fix
  • Optimization
  • Documentation Update
  • Continuous Integration

What were the changes?

NULL check before dereference.

Why are these changes needed?

To prevent dereferencing NULL pointer.

Updated CHANGELOG?

  • Yes
  • No, Does not apply to this PR.

Added/Updated documentation?

  • Yes
  • No, Does not apply to this PR.

Additional Checks

  • I have added tests relevant to the introduced functionality, and the unit tests are passing locally.
  • Any dependent changes have been merged.

🔁 Imported from ROCm/clr#168
🧑‍💻 Originally authored by @dusan-exostellar

dusan-exostellar and others added 2 commits May 28, 2025 19:48
On UNIX, `clearenv` sets `environ` to NULL.
So, NULL is a valid value for `environ`.

Signed-off-by: Dušan Veljko <v-dusan@exostellar.io>
…evelop/dusan-exostellar_clr/environ_null_check
jayhawk-commits pushed a commit that referenced this pull request Aug 18, 2025
ammallya pushed a commit that referenced this pull request Nov 17, 2025
* CMAKE - Remove example build from src/CMakeLists.txt
For some reason it was building examples every time even when not
necessary...
* CMAKE - Format
* Fix drm_example broken PRIu32
* CMAKE - Do NOT create lib64 when building examples
* CMAKE - Examples should only install C and CMake files

---------

Change-Id: I6274b72a085a41b5bd5ae698af798f60a8a092a0
Signed-off-by: Galantsev, Dmitrii <dmitrii.galantsev@amd.com>
ammallya pushed a commit that referenced this pull request Nov 18, 2025
* CMAKE - Remove example build from src/CMakeLists.txt
For some reason it was building examples every time even when not
necessary...
* CMAKE - Format
* Fix drm_example broken PRIu32
* CMAKE - Do NOT create lib64 when building examples
* CMAKE - Examples should only install C and CMake files

---------

Change-Id: I6274b72a085a41b5bd5ae698af798f60a8a092a0
Signed-off-by: Galantsev, Dmitrii <dmitrii.galantsev@amd.com>

[ROCm/amdsmi commit: f9b8066]
ammallya pushed a commit that referenced this pull request Nov 21, 2025
* CMAKE - Remove example build from src/CMakeLists.txt
For some reason it was building examples every time even when not
necessary...
* CMAKE - Format
* Fix drm_example broken PRIu32
* CMAKE - Do NOT create lib64 when building examples
* CMAKE - Examples should only install C and CMake files

---------

Change-Id: I6274b72a085a41b5bd5ae698af798f60a8a092a0
Signed-off-by: Galantsev, Dmitrii <dmitrii.galantsev@amd.com>

[ROCm/amdsmi commit: f9b8066]
ammallya pushed a commit that referenced this pull request Jan 30, 2026
@jayhawk-commits
jayhawk-commits requested a review from a team as a code owner February 26, 2026 21:19
@github-actions

Copy link
Copy Markdown
Contributor

This pull request has been inactive for 25 days and will be marked as stale.

If you would like to keep this PR open, please:

  • Add new commits
  • Add a comment explaining why it should remain open

This PR will be automatically closed in 5 days if no further activity occurs.

@github-actions github-actions Bot added the Stale PR has no activity for 25+ days label May 14, 2026
@github-actions

Copy link
Copy Markdown
Contributor

This pull request has been automatically closed due to inactivity (30 days with no updates).

If you'd like to continue working on this, feel free to reopen the PR or create a new one.

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

Labels

imported pr project: clr Stale PR has no activity for 25+ days

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Issue]: SIGSEGV during HIP initialization if environ is clearenv-ed

2 participants