mirror of
https://github.com/saymrwulf/onnxruntime.git
synced 2026-07-27 20:02:15 +00:00
16 lines
411 B
C++
16 lines
411 B
C++
// Copyright (c) Microsoft Corporation. All rights reserved.
|
|
// Licensed under the MIT License.
|
|
|
|
#include "core/framework/callback.h"
|
|
#if defined(_MSC_VER) && !defined(__clang__)
|
|
#pragma warning(disable : 26409)
|
|
#endif
|
|
namespace onnxruntime {
|
|
void OrtRunCallback(OrtCallback* f) noexcept {
|
|
if (f == nullptr) return;
|
|
if (f->f != nullptr) {
|
|
f->f(f->param);
|
|
delete f;
|
|
}
|
|
}
|
|
} // namespace onnxruntime
|