Skip to content

Commit

Permalink
[WIP] coverity fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
freibold committed Nov 5, 2024
1 parent 44e6441 commit 616add3
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 4 deletions.
2 changes: 1 addition & 1 deletion kernels/common/buffer.h
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ namespace embree
public:
/*! Buffer construction */
RawBufferView()
: ptr_ofs(nullptr), stride(0), num(0), format(RTC_FORMAT_UNDEFINED), modCounter(1), modified(true), userData(0) {}
: ptr_ofs(nullptr), dptr_ofs(nullptr), stride(0), num(0), format(RTC_FORMAT_UNDEFINED), modCounter(1), modified(true), userData(0) {}

public:
/*! sets the buffer view */
Expand Down
1 change: 1 addition & 0 deletions kernels/common/scene.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ namespace embree
maxTimeSegments(0),
geometries_device(nullptr),
geometries_data_device(nullptr),
num_geometries_device(0),
taskGroup(new TaskGroup()),
progressInterface(this), progress_monitor_function(nullptr), progress_monitor_ptr(nullptr), progress_monitor_counter(0)
{
Expand Down
10 changes: 7 additions & 3 deletions tutorials/debug_device_memory/debug_device_memory.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,12 @@ namespace embree
}

int main(int argc, char** argv) {
if (embree::TutorialBenchmark::benchmark(argc, argv)) {
return embree::TutorialBenchmark(embree::renderBenchFunc<embree::Tutorial>).main(argc, argv, "debug_device_memory");
try {
if (embree::TutorialBenchmark::benchmark(argc, argv)) {
return embree::TutorialBenchmark(embree::renderBenchFunc<embree::Tutorial>).main(argc, argv, "debug_device_memory");
}
return embree::Tutorial().main(argc,argv);
} catch (std::exception& e ) {
std::cerr << "Exception caught: " << e.what() << std::endl;
}
return embree::Tutorial().main(argc,argv);
}

0 comments on commit 616add3

Please sign in to comment.