/*1* Copyright (c) 2019 CTCaer2*3* This program is free software; you can redistribute it and/or modify it4* under the terms and conditions of the GNU General Public License,5* version 2, as published by the Free Software Foundation.6*7* This program is distributed in the hope it will be useful, but WITHOUT8* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or9* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for10* more details.11*12* You should have received a copy of the GNU General Public License13* along with this program. If not, see <http://www.gnu.org/licenses/>.14*/1516#ifndef _INIPATCH_H_17#define _INIPATCH_H_1819#include <bdk.h>2021typedef struct _ini_patchset_t22{23char *name;24u32 offset; // section + offset of patch to apply.25u32 length; // In bytes, 0 means last patch.26u8 *src_data; // That must match.27u8 *dst_data; // Gets replaced with.28link_t link;29} ini_patchset_t;3031typedef struct _ini_kip_sec_t32{33char *name;34u8 hash[8];35link_t pts;36link_t link;37} ini_kip_sec_t;3839int ini_patch_parse(link_t *dst, const char *ini_path);4041#endif424344