From: las7 Date: Mon, 23 Mar 2026 17:54:57 +0000 (-0700) Subject: rpc : RCE patch (#20908) X-Git-Tag: upstream/0.0.8611~119 X-Git-Url: https://git.djapps.eu/?a=commitdiff_plain;h=39bf0d3c6a95803e0f41aaba069ffbee26721042;p=pkg%2Fggml%2Fsources%2Fllama.cpp rpc : RCE patch (#20908) --- diff --git a/ggml/src/ggml-rpc/ggml-rpc.cpp b/ggml/src/ggml-rpc/ggml-rpc.cpp index 5d8defad2..0ed2c0dce 100644 --- a/ggml/src/ggml-rpc/ggml-rpc.cpp +++ b/ggml/src/ggml-rpc/ggml-rpc.cpp @@ -1443,7 +1443,9 @@ ggml_tensor * rpc_server::create_node(uint64_t id, const rpc_tensor * tensor = it_ptr->second; struct ggml_tensor * result = deserialize_tensor(ctx, tensor); - if (result == nullptr) { + if (result == nullptr || result->buffer == nullptr) { + GGML_LOG_ERROR("[%s] invalid tensor: null %s (id=%" PRIu64 ")\n", + __func__, result == nullptr ? "tensor" : "buffer", id); return nullptr; } tensor_map[id] = result;