We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 263b8ba commit 93f5f8aCopy full SHA for 93f5f8a
profiling/src/exception.rs
@@ -60,15 +60,14 @@ impl ExceptionProfilingStats {
60
#[cfg(php8)]
61
let exception_name = unsafe { (*exception).class_name() };
62
63
- #[cfg(php7)]
64
let message = unsafe {
65
- zend::zai_str_from_zstr(zend::zai_exception_message((*exception).value.obj).as_mut())
+ #[cfg(php7)]
+ let exception_obj = (*exception).value.obj;
66
+ #[cfg(php8)]
67
+ let exception_obj = exception;
68
+ zend::zai_str_from_zstr(zend::zai_exception_message(exception_obj).as_mut())
69
.into_string()
70
};
- #[cfg(php8)]
- let message = unsafe {
- zend::zai_str_from_zstr(zend::zai_exception_message(exception).as_mut()).into_string()
71
- };
72
73
self.next_sampling_interval();
74
0 commit comments