interplane.Get Omega
Read in your language

CUDApp

CUDA++: AIEN’s GPU machine-code toolchain, runtime and driver client for NVIDIA GPUs without the CUDA toolkit. Hardware coverage and driver replacement limits are explicit.

Brought by drakestapleton

GitHub aien-dev/CUDApp#256 (code only)

closed derived 397c4d5dec4b1d34 #256

Imported from GitHub aien-dev/CUDApp#256 (code only)

GitHub's metadata for this pull request is unavailable: its state is DERIVED from the commits (merged: the head is reachable from this project's main; open: GitHub kept a merge ref; else closed).

Base dba5821dbc68daefb0578a0bf669dd8113af8cb3 · Head f9c1c8a5b25799ce27bfd8b1ab39b6f202932817

github-advanced-security[bot] commented on tools/ampere_corpus.c line 33 on 2026-11-01 18:12 UTC

github-advanced-security[bot] reviewed (COMMENTED) on 2026-11-01 18:12 UTC

cursor[bot] reviewed (APPROVED) on 2026-11-01 18:12 UTC

Risk: low. Approved. Cursor Security Agent completed with no findings that need human review; Cursor Bugbot was not present on this PR.

<div><a href="https://cursor.com/agents/bc-7a8b5868-c6c0-4eef-b292-041c66929c35?cursor_ref=pr_footer&cursor_cta=open_in_web"><picture><source media="(prefers-color-scheme: dark)" srcset="https://cursor.com/assets/images/open-in-web-dark.png"><source media="(prefers-color-scheme: light)" srcset="https://cursor.com/assets/images/open-in-web-light.png"><img alt="Open in Web" width="114" height="28" src="https://cursor.com/assets/images/open-in-web-dark.png"></picture></a> <a href="https://cursor.com/automations/ca4a13aa-d616-11f1-a7e4-4605a90eab71"><picture><source media="(prefers-color-scheme: dark)" srcset="https://cursor.com/assets/images/view-automation-dark.png"><source media="(prefers-color-scheme: light)" srcset="https://cursor.com/assets/images/view-automation-light.png"><img alt="View Automation" width="141" height="28" src="https://cursor.com/assets/images/view-automation-dark.png"></picture></a> </div>

<sub>Sent by Cursor Approval Agent: Pull Request Router and Approver</sub>

Fetch it

A git bundle of the pull request's head, 3885 bytes.

curl -fsSL https://interplane.io/drakestapleton/CUDApp/patches/397c4d5dec4b1d34.bundle -o 397c4d5dec4b1d34.bundle
git fetch 397c4d5dec4b1d34.bundle refs/pull/256/head

Raw bundle · Diff

Provenance

This proposal is imported from GitHub; it is not signed by its author. Its import statement and source record:

github-import 1
aien-dev/CUDApp
256
f9c1c8a5b25799ce27bfd8b1ab39b6f202932817
{"kind":"github-import","owner":"aien-dev","repo":"CUDApp","number":256,"url":"https://github.com/aien-dev/CUDApp/pull/256","export_sha256":"967c79e26a893657b5cdaa45efd442be5dbd2ecfe68e25f9a8c1b5da4d60d452","imported_utc":"2026-11-18T16:39:02Z","metadata":"unavailable","state_derived":true}

Changes

diff --git a/tools/ampere_corpus.c b/tools/ampere_corpus.c
index 99208f9e..c71ad09c 100644
--- a/tools/ampere_corpus.c
+++ b/tools/ampere_corpus.c
@@ -8,6 +8,8 @@
 #include <stdlib.h>
 #include <string.h>
 #include <unistd.h>
+#include <fcntl.h>
+#include <sys/stat.h>
 
 static int is_safe_corpus_dir(const char *dir)
 {
@@ -28,8 +30,10 @@ static void save(const char *dir, unsigned serial, const char *suffix, const voi
     char path[4096];
     int n = snprintf(path, sizeof(path), "%s/%ld-%u.%s", dir, (long)getpid(), serial, suffix);
     if (n < 0 || (size_t)n >= sizeof(path)) abort();
-    FILE *f = fopen(path, "wb");
-    if (!f) { perror(path); abort(); }
+    int fd = open(path, O_WRONLY | O_CREAT | O_TRUNC, S_IRUSR | S_IWUSR);
+    if (fd < 0) { perror(path); abort(); }
+    FILE *f = fdopen(fd, "wb");
+    if (!f) { perror(path); close(fd); abort(); }
     if (fwrite(data, 1, size, f) != size || fclose(f) != 0) abort();
 }