mirror of
https://github.com/topjohnwu/Magisk.git
synced 2025-12-03 12:21:53 +00:00
Reduce duplicate code for MagiskBoot
This commit is contained in:
10
jni/magiskboot/magisk.h
Normal file
10
jni/magiskboot/magisk.h
Normal file
@@ -0,0 +1,10 @@
|
||||
/* magisk.h - Let MagiskBoot use the same error handling API as main magisk program
|
||||
*/
|
||||
|
||||
#ifndef _MAGISK_H_
|
||||
#define _MAGISK_H_
|
||||
|
||||
#define LOGE(err, ...) { fprintf(stderr, __VA_ARGS__); exit(err); }
|
||||
#define PLOGE(fmt, args...) { fprintf(stderr, fmt " failed with %d: %s\n\n", ##args, errno, strerror(errno)); exit(1); }
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user