Type fprintf_function which fits here was defined with this attribute.
Signed-off-by: Stefan Weil <sw@weilnetz.de>
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Message-id:
1437208027-14584-1-git-send-email-sw@weilnetz.de
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
stream_ = stream;
}
- void SetPrintf(int (*printf_fn)(FILE *, const char *, ...)) {
+ void SetPrintf(fprintf_function printf_fn) {
printf_ = printf_fn;
}
}
private:
- int (*printf_)(FILE *, const char *, ...);
+ fprintf_function printf_;
FILE *stream_;
};