[librsvg/wip/aruiz/rust-pixbuf-loader] pixbuf-loader: use cstr!() for c strings



commit e0fe0acf5028618c750d960fc30b3bcac49ebe76
Author: Alberto Ruiz <aruiz redhat com>
Date:   Fri Aug 5 20:13:42 2022 +0100

    pixbuf-loader: use cstr!() for c strings

 gdk-pixbuf-loader/src/lib.rs | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/gdk-pixbuf-loader/src/lib.rs b/gdk-pixbuf-loader/src/lib.rs
index 6c5ffffc2..839e220e4 100644
--- a/gdk-pixbuf-loader/src/lib.rs
+++ b/gdk-pixbuf-loader/src/lib.rs
@@ -203,8 +203,8 @@ const SIGNATURE: [GdkPixbufModulePattern; 3] = [
         relevance: 100,
     },
     GdkPixbufModulePattern {
-        prefix: " <!DOCTYPE svg\0".as_ptr() as *mut c_char,
-        mask: "*             \0".as_ptr() as *mut c_char,
+        prefix: cstr!(" <!DOCTYPE svg").as_ptr() as *mut c_char,
+        mask: cstr!("*             ").as_ptr() as *mut c_char,
         relevance: 100,
     },
     GdkPixbufModulePattern {


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]