Reviewed-by: Nadav Har'El <[email protected]> We could have also changed the interface of HYPERVISOR_console_io, but I guess you preferred not to modify that unmodified BSD header?
-- Nadav Har'El [email protected] On Fri, Jan 20, 2017 at 1:04 PM, 'Sergiy Kibrik' via OSv Development < [email protected]> wrote: > Modify HYPERVISOR_console_write() interface to accept const *char as > argument, > so it is compliant with console::console_driver::write() interface. > Xen does not mangle input buffer upon CONSOLEIO_write hypercall. > > Signed-off-by: Sergiy Kibrik <[email protected]> > --- > bsd/sys/xen/hypervisor.h | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/bsd/sys/xen/hypervisor.h b/bsd/sys/xen/hypervisor.h > index e06bb73..921bb66 100644 > --- a/bsd/sys/xen/hypervisor.h > +++ b/bsd/sys/xen/hypervisor.h > @@ -58,9 +58,9 @@ extern start_info_t *xen_start_info; > extern uint64_t get_system_time(int ticks); > > static inline int > -HYPERVISOR_console_write(char *str, int count) > +HYPERVISOR_console_write(const char *str, int count) > { > - return HYPERVISOR_console_io(CONSOLEIO_write, count, str); > + return HYPERVISOR_console_io(CONSOLEIO_write, count, > const_cast<char*>(str)); > } > > static inline void HYPERVISOR_crash(void) __dead2; > -- > 2.7.4 > > -- > You received this message because you are subscribed to the Google Groups > "OSv Development" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "OSv Development" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
