mirror of
https://github.com/siemens-mobile-hacks/capstone.git
synced 2026-11-25 22:27:31 +00:00
* Add workflow to check for C formatting Rename run-clang-tidy.sh for consistency with clang-format script Don't align trailing comments. It leads to unreproducable formatting. Reformat some comments leading in-compilable up code after clang-format Format generated compatibility header. Add clang-format script Be more verbose with clean-up scripts and fail early. Pass clang-format via command line Install clang-format for the HeaderPatcher * Format code with clang-format-17
26 lines
516 B
C
26 lines
516 B
C
// this tool decodes first input byte feed to OSS fuzz, that encodes arch+mode
|
|
// by Nguyen Anh Quynh, 2019
|
|
|
|
#include <stdio.h>
|
|
#include <inttypes.h>
|
|
|
|
#include <capstone/capstone.h>
|
|
|
|
#include "platform.h"
|
|
|
|
int main(int argc, char **argv)
|
|
{
|
|
unsigned char data;
|
|
|
|
if (argc != 2) {
|
|
printf("Decoding OSS fuzz platform\n");
|
|
printf("Syntax: %s <hex-byte>\n", argv[0]);
|
|
return -1;
|
|
}
|
|
|
|
data = (unsigned int)strtol(argv[1], NULL, 16);
|
|
|
|
printf("cstool arch+mode = %s\n", get_platform_cstoolname(data));
|
|
|
|
return 0;
|
|
}
|