]> git.ipfire.org Git - thirdparty/suricata.git/commitdiff
Rust: fix prototype of parsing function (make pstate mutable)
authorPierre Chifflier <chifflier@wzdftpd.net>
Mon, 15 Jan 2018 21:52:39 +0000 (22:52 +0100)
committerVictor Julien <victor@inliniac.net>
Mon, 26 Mar 2018 09:04:30 +0000 (11:04 +0200)
rust/src/ntp/ntp.rs
rust/src/parser.rs

index 38c665030765ec11b8fd2a6383a727faca778d23..eb03cc3d6ca12badc32281fc90201cc471830f78 100644 (file)
@@ -192,7 +192,7 @@ pub extern "C" fn rs_ntp_state_free(state: *mut libc::c_void) {
 #[no_mangle]
 pub extern "C" fn rs_ntp_parse_request(_flow: *const core::Flow,
                                        state: *mut libc::c_void,
-                                       _pstate: *const libc::c_void,
+                                       _pstate: *mut libc::c_void,
                                        input: *const libc::uint8_t,
                                        input_len: u32,
                                        _data: *const libc::c_void) -> i8 {
@@ -204,7 +204,7 @@ pub extern "C" fn rs_ntp_parse_request(_flow: *const core::Flow,
 #[no_mangle]
 pub extern "C" fn rs_ntp_parse_response(_flow: *const core::Flow,
                                        state: *mut libc::c_void,
-                                       _pstate: *const libc::c_void,
+                                       _pstate: *mut libc::c_void,
                                        input: *const libc::uint8_t,
                                        input_len: u32,
                                        _data: *const libc::c_void) -> i8 {
index efee0c4c45fe020a2015819d36a4c62d8c8eb0c7..c5c689af7b74c1ef5330b1836d7753cb91e77f90 100644 (file)
@@ -117,7 +117,7 @@ macro_rules! cast_pointer {
 
 pub type ParseFn      = extern "C" fn (flow: *const Flow,
                                        state: *mut c_void,
-                                       pstate: *const c_void,
+                                       pstate: *mut c_void,
                                        input: *const u8,
                                        input_len: u32,
                                        data: *const c_void) -> i8;