File tree Expand file tree Collapse file tree 2 files changed +22
-2
lines changed Expand file tree Collapse file tree 2 files changed +22
-2
lines changed Original file line number Diff line number Diff line change
1
+
2
+ /*
3
+ // The original macros are defined as follows:
4
+ # define warnx(...) do {\
5
+ fprintf(stderr, __VA_ARGS__);\
6
+ fprintf(stderr, "\n");\ } while (0)
7
+ # define warn(...) do {\
8
+ fprintf(stderr, "%s: ", strerror(errno));\
9
+ warnx(__VA_ARGS__); } while (0)
10
+ */
11
+ // No-OP: do not report any warning
12
+ # define warnx (...) do { } while(0)
13
+ # define warn (...) do { } while(0)
14
+
15
+ # define errx (eval , ...) do {\
16
+ warnx(__VA_ARGS__);\
17
+ exit(eval); } while (0)
18
+ # define err (eval , ...) do {\
19
+ warn(__VA_ARGS__);\
20
+ exit(eval); } while (0)
Original file line number Diff line number Diff line change 1
1
package main
2
2
3
3
/*
4
- #cgo CPPFLAGS: -DHAVE_UNISTD_H -DHAVE_NANOSLEEP -I. -Idfu-util-0.11/src -I/usr/include/libusb-1.0
5
- #cgo CFLAGS: -DHAVE_UNISTD_H -DHAVE_NANOSLEEP -I. -Idfu-util-0.11/src -I/usr/include/libusb-1.0
4
+ #cgo CPPFLAGS: -DHAVE_UNISTD_H -DHAVE_NANOSLEEP -DHAVE_ERR - I. -Idfu-util-0.11/src -I/usr/include/libusb-1.0
5
+ #cgo CFLAGS: -DHAVE_UNISTD_H -DHAVE_NANOSLEEP -DHAVE_ERR - I. -Idfu-util-0.11/src -I/usr/include/libusb-1.0
6
6
#cgo LDFLAGS: -lusb-1.0
7
7
8
8
#include <dfu.h>
You can’t perform that action at this time.
0 commit comments