mirror of
https://github.com/chatmail/core.git
synced 2026-05-20 23:36:30 +03:00
run rustfmt
This commit is contained in:
13
src/dc_qr.rs
13
src/dc_qr.rs
@@ -63,10 +63,9 @@ pub unsafe fn dc_check_qr(context: &Context, qr: *const libc::c_char) -> *mut dc
|
|||||||
strlen(b"OPENPGP4FPR:\x00" as *const u8 as *const libc::c_char),
|
strlen(b"OPENPGP4FPR:\x00" as *const u8 as *const libc::c_char),
|
||||||
) == 0i32
|
) == 0i32
|
||||||
{
|
{
|
||||||
payload =
|
payload = dc_strdup(
|
||||||
dc_strdup(&*qr.offset(strlen(
|
&*qr.offset(strlen(b"OPENPGP4FPR:\x00" as *const u8 as *const libc::c_char) as isize),
|
||||||
b"OPENPGP4FPR:\x00" as *const u8 as *const libc::c_char,
|
);
|
||||||
) as isize));
|
|
||||||
let mut fragment: *mut libc::c_char = strchr(payload, '#' as i32);
|
let mut fragment: *mut libc::c_char = strchr(payload, '#' as i32);
|
||||||
if !fragment.is_null() {
|
if !fragment.is_null() {
|
||||||
*fragment = 0i32 as libc::c_char;
|
*fragment = 0i32 as libc::c_char;
|
||||||
@@ -173,15 +172,13 @@ pub unsafe fn dc_check_qr(context: &Context, qr: *const libc::c_char) -> *mut dc
|
|||||||
if !semicolon_0.is_null() {
|
if !semicolon_0.is_null() {
|
||||||
*semicolon_0 = 0i32 as libc::c_char
|
*semicolon_0 = 0i32 as libc::c_char
|
||||||
}
|
}
|
||||||
if strcasecmp(key, b"EMAIL\x00" as *const u8 as *const libc::c_char) == 0i32
|
if strcasecmp(key, b"EMAIL\x00" as *const u8 as *const libc::c_char) == 0i32 {
|
||||||
{
|
|
||||||
semicolon_0 = strchr(value, ';' as i32);
|
semicolon_0 = strchr(value, ';' as i32);
|
||||||
if !semicolon_0.is_null() {
|
if !semicolon_0.is_null() {
|
||||||
*semicolon_0 = 0i32 as libc::c_char
|
*semicolon_0 = 0i32 as libc::c_char
|
||||||
}
|
}
|
||||||
addr = dc_strdup(value)
|
addr = dc_strdup(value)
|
||||||
} else if strcasecmp(key, b"N\x00" as *const u8 as *const libc::c_char)
|
} else if strcasecmp(key, b"N\x00" as *const u8 as *const libc::c_char) == 0i32
|
||||||
== 0i32
|
|
||||||
{
|
{
|
||||||
semicolon_0 = strchr(value, ';' as i32);
|
semicolon_0 = strchr(value, ';' as i32);
|
||||||
if !semicolon_0.is_null() {
|
if !semicolon_0.is_null() {
|
||||||
|
|||||||
Reference in New Issue
Block a user