Re: [Spice-devel] [PATCH spice-gtk v2] session: initialize USB device manager on session creation

2019-01-03 Thread Marc-André Lureau
On Thu, Jan 3, 2019 at 8:12 PM Christophe Fergeau wrote: > > Hey, > > On Thu, Jan 03, 2019 at 03:41:35PM +0400, marcandre.lur...@redhat.com wrote: > > From: Marc-André Lureau > > > > Simple command line tools simply connect all channels, however > > usbred

Re: [Spice-devel] [PATCH spice-server 20/33 v2] replay: Force binary mode on input on Windows

2019-01-03 Thread Marc-André Lureau
On Thu, Jan 3, 2019 at 3:31 PM Frediano Ziglio wrote: > > If input contains the binary record we can't have it modified > during read. > > Signed-off-by: Frediano Ziglio Reviewed-by: Marc-André Lureau > --- > server/tests/replay.c | 5 - > 1 file changed, 4 i

Re: [Spice-devel] [PATCH spice-gtk 3/3] meson: don't link with all dependencies

2019-01-02 Thread Marc-André Lureau
Hi On Wed, Jan 2, 2019 at 4:01 PM Frediano Ziglio wrote: > > > > > From: Marc-André Lureau > > > > Split lib dependencies in 3 groups: glib, gtk, and acl. > > > > Fixes: > > https://gitlab.freedesktop.org/spice/spice-gtk/issue

Re: [Spice-devel] [PATCH spice-gtk 2/3] usb-device-widget: replace deprecated Gtk+ API usage

2019-01-02 Thread Marc-André Lureau
ping On Sat, Dec 22, 2018 at 6:53 PM wrote: > > From: Marc-André Lureau > > Use widget properties instead, as recommended in the documentation. > The UI doesn't seem to have changed after these modifications. > > Signed-off-by: Marc-André Lureau > --- > s

Re: [Spice-devel] [PATCH spice-gtk 3/3] meson: don't link with all dependencies

2019-01-02 Thread Marc-André Lureau
ping On Sat, Dec 22, 2018 at 6:53 PM wrote: > > From: Marc-André Lureau > > Split lib dependencies in 3 groups: glib, gtk, and acl. > > Fixes: > https://gitlab.freedesktop.org/spice/spice-gtk/issues/77 > > Signed-off-by: Marc-André Lureau &g

Re: [Spice-devel] [PATCH spice-gtk 1/3] meson: use 0.49 support for pie

2019-01-02 Thread Marc-André Lureau
Hi On Sat, Dec 22, 2018 at 7:06 PM Frediano Ziglio wrote: > > > > > From: Marc-André Lureau > > > > Fixes > > WARNING: Use the 'pie' kwarg instead of passing '-fpie' manually to > > 'spice-client-glib-usb-acl-helper' > > > > Signed-off-by: Mar

Re: [Spice-devel] [PATCH spice-server 04/33] Avoids %m in formatting for Windows

2018-12-22 Thread Marc-André Lureau
gt; > > +if (sscanf(codecs, "%128[0-9a-zA-Z_]:%128[0-9a-zA-Z_]%n", > > > encoder_buf, > > > codec_buf, ) == 2) { > > > +*encoder = strdup(encoder_buf); > > > +*codec = strdup(codec_buf); > > > +#endi

Re: [Spice-devel] [PATCH spice-server 25/33] tests: Exclude tests that cannot work on Windows

2018-12-22 Thread Marc-André Lureau
On Fri, Dec 21, 2018 at 4:04 PM Frediano Ziglio wrote: > > test-stream test is passing file descriptor using Unix socket. > test-stat-file needs some porting work of mmap feature. > > Signed-off-by: Frediano Ziglio Reviewed-by: Marc-André Lureau > --- > server/

Re: [Spice-devel] [PATCH spice-server 32/33] Use structure for socket_t type instead of just a typedef

2018-12-22 Thread Marc-André Lureau
l@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/spice-devel -- Marc-André Lureau ___ Spice-devel mailing list Spice-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/spice-devel

Re: [Spice-devel] [PATCH spice-server 31/33] replay: Port to Windows

2018-12-22 Thread Marc-André Lureau
On Fri, Dec 21, 2018 at 4:04 PM Frediano Ziglio wrote: > > Client process termination did not work for Windows, used Win32 > APIs. ok.. > > Signed-off-by: Frediano Ziglio Reviewed-by: Marc-André Lureau > --- > server/tests/replay.c | 11 +-- > 1 file cha

Re: [Spice-devel] [PATCH spice-server 23/33] tests: Provide alarm replacement for Windows

2018-12-22 Thread Marc-André Lureau
On Fri, Dec 21, 2018 at 4:04 PM Frediano Ziglio wrote: > > Signed-off-by: Frediano Ziglio Reviewed-by: Marc-André Lureau > --- > server/tests/Makefile.am | 2 + > server/tests/test-channel.c | 1 + > server/tests/test-loop.c | 1 + > ser

Re: [Spice-devel] [PATCH spice-server 30/33] Disable recording filtering for Windows

2018-12-22 Thread Marc-André Lureau
g_setenv("SPICE_WORKER_RECORD_FILTER", "gzip", 1); > } > > // delete possible stale test output > @@ -95,6 +95,9 @@ int > main(void) > { > test_record(false); > +// TODO implement on Windows > +#ifndef _WIN32 > test_record(true); > +#endif > return 0; > } >

Re: [Spice-devel] [PATCH spice-server 29/33] reds: Explicitly include inttypes.h

2018-12-22 Thread Marc-André Lureau
On Fri, Dec 21, 2018 at 4:04 PM Frediano Ziglio wrote: > > MingW does not include this header while including stdint.h so > on Windows you need to include it. > > Signed-off-by: Frediano Ziglio Reviewed-by: Marc-André Lureau > --- > server/reds.h | 1 + > 1 f

Re: [Spice-devel] [PATCH spice-server 28/33] test-display-base: Port to Windows

2018-12-22 Thread Marc-André Lureau
On Fri, Dec 21, 2018 at 4:04 PM Frediano Ziglio wrote: > > Use GLib function to launch and wait process exit. > > Signed-off-by: Frediano Ziglio Reviewed-by: Marc-André Lureau > --- > server/tests/regression-test.py | 4 ++-- > server/tests/tes

Re: [Spice-devel] [PATCH spice-server 22/33] event-loop: Port to Windows

2018-12-22 Thread Marc-André Lureau
On Fri, Dec 21, 2018 at 4:04 PM Frediano Ziglio wrote: > > Use g_io_channel_win32_new_socket instead of g_io_channel_unix_new > > Signed-off-by: Frediano Ziglio Reviewed-by: Marc-André Lureau > --- > server/event-loop.c | 5 + > 1 file changed, 5 insertions(+) &g

Re: [Spice-devel] [PATCH spice-server 26/33] test-stat: Adjust delay checks

2018-12-22 Thread Marc-André Lureau
g_assert_cmpuint(info.total, >=, 5000); > +g_assert_cmpuint(info.total, >=, 500); > g_assert_cmpuint(info.orig_size, ==, 1100); > g_assert_cmpuint(info.comp_size, ==, 550); > #endif > -- > 2.17.2 > > __

Re: [Spice-devel] [PATCH spice-server 21/33] dispatcher: Port to Windows

2018-12-22 Thread Marc-André Lureau
select(1, , NULL, NULL, NULL); > +continue; > +} > +#endif > return -1; > } > if (ret == 0) { > -- > 2.17.2 > > ___ > Spice-devel mailing list > Spice-devel@list

Re: [Spice-devel] [PATCH spice-server 24/33] test-listen: Exclude Unix sockets part under Windows

2018-12-22 Thread Marc-André Lureau
On Fri, Dec 21, 2018 at 4:04 PM Frediano Ziglio wrote: > > Windows does not support Unix sockets. > > Signed-off-by: Frediano Ziglio Reviewed-by: Marc-André Lureau > --- > server/tests/test-listen.c | 10 ++ > 1 file changed, 10 insertions(+) > > dif

Re: [Spice-devel] [PATCH spice-server 19/33] windows: Disable code not working on Windows

2018-12-22 Thread Marc-André Lureau
Ziglio Looks good, Reviewed-by: Marc-André Lureau > --- > server/red-channel-client.c | 2 ++ > server/red-stream.c | 11 ++- > server/red-stream.h | 2 ++ > server/red-worker.c | 6 ++ > server/reds.c |

Re: [Spice-devel] [PATCH spice-server 20/33] replay: Force binary mode on input on Windows

2018-12-22 Thread Marc-André Lureau
On Fri, Dec 21, 2018 at 4:04 PM Frediano Ziglio wrote: > > If input contains the binary record we can't have it modified > during read. > > Signed-off-by: Frediano Ziglio Or the more portable freopen(NULL, "rb", stdin);? anyway Reviewed-by: Marc-André Lureau >

Re: [Spice-devel] [PATCH spice-server 18/33] windows: Undefine some conflicting preprocessor macros

2018-12-22 Thread Marc-André Lureau
> +#undef interface > + > #define REDS_MAX_STAT_NODES 100 > > static void reds_client_monitors_config(RedsState *reds, > VDAgentMonitorsConfig *monitors_config); > -- > 2.17.2 > > _______ >

Re: [Spice-devel] [PATCH spice-server 05/33] sys-socket: Introduce some utility to make sockets more portable

2018-12-22 Thread Marc-André Lureau
e, value, len); > +if (res < 0) { > + socket_win32_set_errno(); > +} > +return res; > +} > + > +static inline int > +socket_setopt(socket_t sock, int lvl, int type, const void *value, socklen_t > len) > +{ > +int res = setsockopt(socket_get_raw(sock), lvl, type, value, len); > +if (res < 0) { > +socket_win32_set_errno(); > +} > +return res; > +} > + > +static inline int > +socket_listen(socket_t sock, int backlog) > +{ > +int res = listen(socket_get_raw(sock), backlog); > +if (res < 0) { > +socket_win32_set_errno(); > +} > +return res; > +} > +#endif > + > +// common part > +// > + > +#define socket_getpeername(sock, name, len) \ > +getpeername(socket_get_raw(sock), name, len) > +#define socket_getsockname(sock, name, len) \ > +getsockname(socket_get_raw(sock), name, len) > +#define socket_new(af, type, flags) \ > +SOCKET_FROM_INT(socket(af, type, flags)) > +// FIXME windows, set error! > +#define socket_bind(sock, addr, len) \ > +bind(socket_get_raw(sock), addr, len) > + > +#endif // RED_SYS_SOCKET_H_ > -- > 2.17.2 > Looks ok overall. It's a bit sad that Spice doesn't use GIO instead, GSocket would do most of this, and more. There is also GIOChannel, although it's a bit more archaic, g_io_channel_win32_new_socket() etc.. -- Marc-André Lureau ___ Spice-devel mailing list Spice-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/spice-devel

Re: [Spice-devel] [PATCH spice-server 06/33] sys-socket: Add socket_newpair utility

2018-12-22 Thread Marc-André Lureau
cket_write(sock, buf, len) write(socket_get_raw(sock), buf, len) > #define socket_writev(sock, iov, n) writev(socket_get_raw(sock), iov, n) > @@ -170,6 +175,8 @@ socket_listen(socket_t sock, int backlog) > } > return res; > } > + > +int socket_newpair(int type, int protocol, socket_t sv[2]); > #endif > &

Re: [Spice-devel] [PATCH spice-server 04/33] Avoids %m in formatting for Windows

2018-12-22 Thread Marc-André Lureau
'\0') { > free(*codec); > -- > 2.17.2 > > ___________ > Spice-devel mailing list > Spice-devel@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/spice-devel -- Marc-André Lureau ___ Spice-devel mailing list Spice-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/spice-devel

Re: [Spice-devel] [PATCH spice-server 03/33] build: Detect Windows build and change some definitions

2018-12-22 Thread Marc-André Lureau
Hi On Fri, Dec 21, 2018 at 4:03 PM Frediano Ziglio wrote: > > Windows needs some specific setting to use network. > > Signed-off-by: Frediano Ziglio with neat below Reviewed-by: Marc-André Lureau > --- > configure.ac | 18 +- > server/Makefile

Re: [Spice-devel] [PATCH spice-server 01/33] Use PRIxPTR constant for string formatting

2018-12-22 Thread Marc-André Lureau
set); > +spice_debug("not enough data yet. %" PRIdPTR, cmc->offset); > return; > } > msg_header = (VDAgentMessage *)cmc->buffer; > @@ -1157,7 +1157,7 @@ static void > reds_on_main_agent_monitors_config(RedsState *reds, > goto overflow; > } > if (msg_header->size > cmc->offset - sizeof(VDAgentMessage)) { > -spice_debug("not enough data yet. %zd", cmc->offset); > +spice_debug("not enough data yet. %" PRIdPTR, cmc->offset); > return; > } > if (msg_header->size < sizeof(VDAgentMonitorsConfig)) { > -- > 2.17.2 > > ___ > Spice-devel mailing list > Spice-devel@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/spice-devel -- Marc-André Lureau ___ Spice-devel mailing list Spice-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/spice-devel

Re: [Spice-devel] [PATCH spice-server 02/33] windows: Do not include headers not available on Windows

2018-12-22 Thread Marc-André Lureau
On Fri, Dec 21, 2018 at 4:03 PM Frediano Ziglio wrote: > > This is a preparatory patch for next portability patches > > Signed-off-by: Frediano Ziglio Reviewed-by: Marc-André Lureau > --- > server/dispatcher.c | 2 ++ > server/net-utils.c

Re: [Spice-devel] [PATCH spice] reds: don't unlink existing UNIX socket

2018-12-20 Thread Marc-André Lureau
Hi On Thu, Dec 20, 2018 at 5:44 PM Daniel P. Berrangé wrote: > > On Thu, Dec 20, 2018 at 05:37:40PM +0400, marcandre.lur...@redhat.com wrote: > > From: Marc-André Lureau > > > > Since "reds: add Unix socket support" (commit > > 5365caeaae537f564d1

Re: [Spice-devel] [PATCH spice-protocol] Add Spice URI Scheme document

2018-12-19 Thread Marc-André Lureau
Hi On Wed, Dec 19, 2018 at 6:43 PM Frediano Ziglio wrote: > > > > > From: Marc-André Lureau > > > > A recent discussion about Spice URI scheme on the QEMU mailing list > > with Gerd prompted me to make an effort to standardize the Spice URIs > > usage.

Re: [Spice-devel] [PATCH 2/2] spice: Bump required spice-server version to 0.12.6

2018-11-28 Thread Marc-André Lureau
.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/spice-devel -- Marc-André Lureau ___ Spice-devel mailing list Spice-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/spice-devel

Re: [Spice-devel] [PATCH 2/2] spice: Bump required spice-server version to 0.12.6

2018-11-28 Thread Marc-André Lureau
gt; -#endif > > #ifdef HAVE_SPICE_GL > if (qemu_opt_get_bool(opts, "gl", 0)) { > diff --git a/ui/spice-display.c b/ui/spice-display.c > index 52f8cb5ae1..15a3796d58 100644 > --- a/ui/spice-display.c > +++ b/ui/spice-display.c > @@ -509,13 +509,6 @@ static void inte

Re: [Spice-devel] [PATCH spice] smartcard: set char device state

2018-11-28 Thread Marc-André Lureau
it these unrelated > libcacard issues... :-/ ) What about taking it now? thanks > > Christophe > > On Mon, Aug 20, 2018 at 03:51:41PM +0200, Marc-André Lureau wrote: > > Hi > > On Mon, Aug 20, 2018 at 2:06 PM Frediano Ziglio wrote: > > > > > > Wi

Re: [Spice-devel] [PATCH] spice: Use new SpiceImageCompression definition

2018-11-28 Thread Marc-André Lureau
-08/msg00486.html "bump spice-server required version to 0.12.6" > thanks, > Gerd > > ___ > Spice-devel mailing list > Spice-devel@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/spice-

Re: [Spice-devel] [PATCH spice-server 1/2] ci: Merge new glib.supp file

2018-11-21 Thread Marc-André Lureau
object_new_valist > } > > -{ > - getaddrinfo > - Memcheck:Leak > - fun:malloc > - ... > - fun:__resolv_conf_allocate > - ... > - fun:getaddrinfo > -} > - > { > px_proxy_factory_get_proxies > Memcheck:Leak &g

Re: [Spice-devel] [spice-gtk v3 1/2] mingw: Use G_GUINT64_FORMAT with glib printing functions

2018-10-04 Thread Marc-André Lureau
T64_FORMAT ", ref %" > G_GUINT64_FORMAT, > + __FUNCTION__, > +d->image.width, d->image.height, d->image.id, > +d->image.id - d->image.win_head_dist); > } > > static void decode(SpiceGlzDecoder *decoder, > diff --git a/src/spice-channel-cache.h b/src/spice-channel-cache.h > index fc25c354..e6e01e11 100644 > --- a/src/spice-channel-cache.h > +++ b/src/spice-channel-cache.h > @@ -18,7 +18,6 @@ > #ifndef SPICE_CHANNEL_CACHE_H_ > # define SPICE_CHANNEL_CACHE_H_ > > -#include /* For PRIx64 */ > #include "common/mem.h" > #include "common/ring.h" > > -- > 2.19.0 > > ___ > Spice-devel mailing list > Spice-devel@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/spice-devel -- Marc-André Lureau ___ Spice-devel mailing list Spice-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/spice-devel

Re: [Spice-devel] [spice-gtk v3 2/2] mingw: Fix compilation breakage because of memmem use

2018-10-04 Thread Marc-André Lureau
ot;\r\n")) != NULL) { > GError *err = NULL; > > *crlf = '\0'; > -- > 2.19.0 > > ___ > Spice-devel mailing list > Spice-devel@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/spice-devel -- Marc-André Lureau _

Re: [Spice-devel] [PATCH spice-gtk] NEWS: Update

2018-10-04 Thread Marc-André Lureau
el mailing list > > Spice-devel@lists.freedesktop.org > > https://lists.freedesktop.org/mailman/listinfo/spice-devel > ___ > Spice-devel mailing list > Spice-devel@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/spice-devel -- Marc-André Lureau ___ Spice-devel mailing list Spice-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/spice-devel

Re: [Spice-devel] [PATCH spice-gtk] ci: Compile with MingW

2018-10-01 Thread Marc-André Lureau
make install) > + - NOCONFIGURE=yes ./autogen.sh > + - PYTHON=python3 mingw64-configure --enable-static > + - make -j4 > -- > 2.17.1 > > ___________ > Spice-devel mailing list > Spice-devel@lists.freedesktop.org > https://lists.freedesktop.org/m

Re: [Spice-devel] [spice-gtk] qmp-helper/build: disable qmp build under mingw

2018-10-01 Thread Marc-André Lureau
lt), error); > } > + > +#else > +/* public procedures for compatibility */ > + > +#endif /* USE_JSON*/ > -- > 2.17.0 > > ___ > Spice-devel mailing list > Spice-devel@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/spice-devel -- Marc-André Lureau ___ Spice-devel mailing list Spice-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/spice-devel

Re: [Spice-devel] [RFC] server: Add make-it-quick Makefile and support files

2018-09-28 Thread Marc-André Lureau
> Thanks > Christophe > > > On 28 Sep 2018, at 13:15, Marc-André Lureau > > wrote: > > > > Hi > > > > On Fri, Sep 28, 2018 at 2:19 PM Christophe Fergeau > > wrote: > >> > >> Hey, > >> > >> We just added meson suppo

Re: [Spice-devel] [RFC] server: Add make-it-quick Makefile and support files

2018-09-28 Thread Marc-André Lureau
rver.h spice-server-enums.c.tmpl > > + $(PRINT_GENERATE) glib-mkenums --template spice-server-enums.c.tmpl > > $< > $@ > > + > > +spice-server-enums.h: spice-server.h spice-server-enums.h.tmpl > > + $(PRINT_GENERATE) glib-mkenums --template spice-server-enums.h.tmpl > > $< > $@ > > + > > +spice-version.h: spice-version.h.in > > + $(PRINT_GENERATE) $(GEN_$@) > > +GEN_spice-version.h= \ > > + sed < $< > $@ \ > > + -e 's|@SPICE_SERVER_VERSION@|$(SPICE_SERVER_VERSION)|g' > > + > > +$(GENERATED): $(MIQ_MAKEDEPS) > > diff --git a/server/config/check_lz4_compress_fast_continue.c > > b/server/config/check_lz4_compress_fast_continue.c > > new file mode 100644 > > index ..91937729 > > --- /dev/null > > +++ b/server/config/check_lz4_compress_fast_continue.c > > @@ -0,1 +1,16 @@ > > +#include > > + > > +int main() > > +{ > > +if (0) { > > +LZ4_stream_t *stream = NULL; > > +const char *in_buf = NULL; > > +char *compressed_buf = NULL; > > +int in_size = 0; > > +int bound_size = 0; > > +LZ4_compress_fast_continue(stream, > > + in_buf, compressed_buf, > > + in_size, bound_size, 1); > > +} > > +return 0; > > +} > > -- > > 2.13.5 (Apple Git-94) > > ___ > > Spice-devel mailing list > > Spice-devel@lists.freedesktop.org > > https://lists.freedesktop.org/mailman/listinfo/spice-devel > ___ > Spice-devel mailing list > Spice-devel@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/spice-devel -- Marc-André Lureau ___ Spice-devel mailing list Spice-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/spice-devel

Re: [Spice-devel] [PATCH spice-gtk 2/3] tests: Add missing static statement

2018-09-27 Thread Marc-André Lureau
___ > Spice-devel mailing list > Spice-devel@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/spice-devel -- Marc-André Lureau ___ Spice-devel mailing list Spice-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/spice-devel

Re: [Spice-devel] [PATCH spice-gtk 3/4] qmp: release channel on dispose

2018-09-27 Thread Marc-André Lureau
Hi On Thu, Sep 27, 2018 at 3:22 PM Victor Toso wrote: > > On Wed, Sep 26, 2018 at 06:56:23PM +0400, marcandre.lur...@redhat.com wrote: > > From: Marc-André Lureau > > > > Do not leak the strong channel ref. > > > > Signed-off-by: Marc-André Lureau > >

Re: [Spice-devel] [PATCH spice-gtk v3] glib: add SpiceQmpPort helper

2018-09-27 Thread Marc-André Lureau
Hi On Thu, Sep 27, 2018 at 12:26 PM Javier Celaya wrote: > El vie, 21-09-2018 a las 14:34 +0400, marcandre.lur...@redhat.com > escribió: > > From: Marc-André Lureau > > > Add a few helper functions to deal with a QMP port channel, in order > > to ease json handling,

Re: [Spice-devel] [PATCH spice-gtk 2/2] spice-session: Make some functions static

2018-09-27 Thread Marc-André Lureau
r *dir) > +static void spice_session_set_shared_dir(SpiceSession *session, const gchar > *dir) > { > g_return_if_fail(SPICE_IS_SESSION(session)); > > -- > 2.17.1 > > ___ > Spice-devel mailing list > Spice-devel@lists.freedesktop.o

Re: [Spice-devel] [PATCH spice-gtk 1/2] spice-session: Remove unused spice_session_set_main_channel function

2018-09-27 Thread Marc-André Lureau
gt; - > G_GNUC_INTERNAL > gboolean spice_session_set_migration_session(SpiceSession *session, > SpiceSession *mig_session) > { > -- > 2.17.1 > > ___________ > Spice-devel mailing list > Spice-devel@lists.freedesktop.org > https://lists.freed

Re: [Spice-devel] [PATCH spice-gtk] spice-session: Remove last usage of ring_ functions

2018-09-26 Thread Marc-André Lureau
g_signal_emit(session, signals[SPICE_SESSION_DISCONNECTED], 0); > } > g_object_unref(session); > @@ -2291,28 +2252,24 @@ static void > spice_session_channel_destroy(SpiceSession *session, SpiceChannel *c > g_return_if_fail(SPICE_IS_CHANNEL(channel)); > >

Re: [Spice-devel] [PATCH spice-gtk 0/4] QMP helper misc fixes

2018-09-26 Thread Marc-André Lureau
be a dependency of some base package. mingw-json-glib is available in f28. -- Marc-André Lureau ___ Spice-devel mailing list Spice-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/spice-devel

Re: [Spice-devel] [PATCH spice-gtk] gitabl-ci: fix CI build

2018-09-25 Thread Marc-André Lureau
Hi On Tue, Sep 25, 2018 at 5:47 PM Eduardo Lima (Etrunko) wrote: > > On 9/24/18 6:04 PM, marcandre.lur...@redhat.com wrote: > > From: Marc-André Lureau > > > > I broke gitlab CI in commit f61534d by introducing json-glib > > dependency. Instead of depending o

Re: [Spice-devel] [PATCH spice-gtk] gitabl-ci: fix CI build

2018-09-25 Thread Marc-André Lureau
Hi On Tue, Sep 25, 2018 at 12:18 PM Frediano Ziglio wrote: > > > > > From: Marc-André Lureau > > > > I broke gitlab CI in commit f61534d by introducing json-glib > > dependency. Instead of depending on dnf builddep, list the build > > dependencie

Re: [Spice-devel] [PATCH spice-gtk] gitabl-ci: fix CI build

2018-09-24 Thread Marc-André Lureau
Hi On Tue, Sep 25, 2018 at 2:19 AM Victor Toso wrote: > > Hi, > > On Tue, Sep 25, 2018 at 01:04:03AM +0400, marcandre.lur...@redhat.com wrote: > > From: Marc-André Lureau > > > > I broke gitlab CI in commit f61534d by introducing json-glib > > dependency.

Re: [Spice-devel] [PATCH spice-gtk v2] glib: add SpiceQmpPort helper

2018-09-21 Thread Marc-André Lureau
Hi On Fri, Sep 21, 2018 at 1:24 PM Victor Toso wrote: > > Hi, > > On Thu, Sep 20, 2018 at 12:01:37AM +0400, marcandre.lur...@redhat.com wrote: > > From: Marc-André Lureau > > > > Add a few helper functions to deal with a QMP port channel, in order > > to ea

Re: [Spice-devel] [spice-gtk v4 12/13] cd-sharing: implementation of new USB widget

2018-09-21 Thread Marc-André Lureau
Hi On Thu, Sep 20, 2018 at 9:17 PM Yuri Benditovich wrote: > > > > On Thu, Sep 20, 2018 at 4:24 PM, Marc-André Lureau > wrote: >> >> Hi >> >> On Thu, Sep 20, 2018 at 5:09 PM Yuri Benditovich >> wrote: >> > >> > Hi >> &

Re: [Spice-devel] [spice-gtk v4 12/13] cd-sharing: implementation of new USB widget

2018-09-20 Thread Marc-André Lureau
Hi On Thu, Sep 20, 2018 at 5:09 PM Yuri Benditovich wrote: > > Hi > > On Wed, Sep 19, 2018 at 6:43 PM, Marc-André Lureau > wrote: >> >> Hi >> >> On Tue, Sep 18, 2018 at 8:05 PM Yuri Benditovich >> wrote: >> > >> > >> &g

Re: [Spice-devel] [spice-gtk v4 00/13] CD sharing feature

2018-09-20 Thread Marc-André Lureau
>> > is potentially unlimited (using multi-unit device) >> >> No, the limit is 16 LUNs for bulk-only transport. Should be enough >> though, I have a hard time to imagine use cases where you need more >> than 2-3 isos. >> >> Note that you can't

Re: [Spice-devel] [PATCH spice-gtk] glib: add SpiceQmpPort helper

2018-09-19 Thread Marc-André Lureau
Hi On Wed, Sep 19, 2018 at 7:06 PM Victor Toso wrote: > > Hi, > > On Wed, Sep 19, 2018 at 05:51:13PM +0400, Marc-André Lureau wrote: > > Hi > > > > On Wed, Sep 19, 2018 at 3:26 PM Victor Toso wrote: > > > > > > Hi, > > > > > &g

Re: [Spice-devel] [spice-gtk v4 12/13] cd-sharing: implementation of new USB widget

2018-09-19 Thread Marc-André Lureau
Hi On Tue, Sep 18, 2018 at 8:05 PM Yuri Benditovich wrote: > > > > On Tue, Sep 18, 2018 at 12:15 PM, Marc-André Lureau > wrote: >> >> Hi >> >> On Tue, Sep 18, 2018 at 12:04 PM Yuri Benditovich >> wrote: >> > >> >

Re: [Spice-devel] [PATCH spice-gtk] glib: add SpiceQmpPort helper

2018-09-19 Thread Marc-André Lureau
Hi On Wed, Sep 19, 2018 at 3:26 PM Victor Toso wrote: > > Hi, > > Tested the qmp part, so far, so good. Some comments/suggestions > bellow. > > On Fri, Aug 10, 2018 at 03:44:19PM +0200, marcandre.lur...@redhat.com wrote: > > From: Marc-André Lureau > > >

Re: [Spice-devel] [spice-gtk v4 00/13] CD sharing feature

2018-09-18 Thread Marc-André Lureau
create mode 100644 src/usb-device-redir-widget.c > > -- > 2.9.4 > > ___ > Spice-devel mailing list > Spice-devel@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/spice-devel -- Marc-André Lureau ___ Spice-devel mailing list Spice-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/spice-devel

Re: [Spice-devel] [spice-gtk v4 12/13] cd-sharing: implementation of new USB widget

2018-09-18 Thread Marc-André Lureau
Hi On Tue, Sep 18, 2018 at 12:04 PM Yuri Benditovich wrote: > > > > On Tue, Sep 18, 2018 at 9:10 AM, Victor Toso wrote: >> >> On Mon, Sep 17, 2018 at 04:23:02PM +0300, Yuri Benditovich wrote: >> > New USB widget supports all the functionality related to >> > redirection of local USB device (as

Re: [Spice-devel] [spice-gtk] display: Trigger wheel scrolling after one 'click'

2018-09-17 Thread Marc-André Lureau
>= 1) { > if (d->scroll_delta_y < 0) { > press_and_release(display, SPICE_MOUSE_BUTTON_UP, > button_state); > d->scroll_delta_y += 1; > -- > 2.17.1 > > ___ > Spice-devel

Re: [Spice-devel] [spice-gtk v2 2/2] cd-sharing: Implementation of CD sharing feature

2018-09-13 Thread Marc-André Lureau
Hi On Thu, Sep 13, 2018 at 2:08 PM Yuri Benditovich wrote: > > Regarding the new widget: > New widget introduced in order to keep the backward compatibility. > There is an option (described in the commit comment) to keep the old look of > the widget (this will suppress the cd-sharing, of

Re: [Spice-devel] [PATCH spice-gtk] glib: add SpiceQmpPort helper

2018-08-29 Thread Marc-André Lureau
Hi On Fri, Aug 10, 2018 at 3:45 PM wrote: > > From: Marc-André Lureau > > Add a few helper functions to deal with a QMP port channel, in order > to ease json handling, and wrapping a few commands. > > (by convention, the port should have the name > "org.

Re: [Spice-devel] [RFC PATCH spice-common v2 02/20] A version 2 of the MousePosition message

2018-08-23 Thread Marc-André Lureau
t is simply not the correct way > to work with IDs. It is spreading the wrong concept more across the > code base. It will make the code even more confusing and it's even more > probable it's going to cause more trouble in the future. (do you need > more? :)) The argument that the xrandr

Re: [Spice-devel] [RFC PATCH spice-common v2 02/20] A version 2 of the MousePosition message

2018-08-23 Thread Marc-André Lureau
d server). > > > I think Jonathon, whom is mainly working on multi monitor support, was > > > thinking on not using these mappings but instead using a single > > > DisplayChannel > > > for a single vGPU device even with multiple outputs. > > > Personally I w

Re: [Spice-devel] [RFC PATCH spice-common v2 02/20] A version 2 of the MousePosition message

2018-08-23 Thread Marc-André Lureau
to bind/unbind the outputs dynamically. This last > however won't solve the agent not knowing what a given display_id is and > would require some protocol updates (but not between client and server). > I think Jonathon, whom is mainly working on multi monitor support, was > thinking on not using these mappings but instead using a single DisplayChannel > for a single vGPU device even with multiple outputs. > Personally I would remove the restriction (mainly implementation, not > protocol) of having the primary surface only with surface_id == 0, this > was discussed also with Gerd when atomic settings were implemented in Linux > driver. That doesn't change the argument about MonitorConfig display_id vs channel_id & monitor_id. The only reason I have so far is that the agent is not able to map a display_id to the correct channel/monitor. Yet, I don't understand why and why the protocol would need to change. -- Marc-André Lureau ___ Spice-devel mailing list Spice-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/spice-devel

Re: [Spice-devel] [RFC PATCH spice-common v2 02/20] A version 2 of the MousePosition message

2018-08-22 Thread Marc-André Lureau
criptive name (e.g. > display_channel, or display_channel_id). > > Or if nobody else cares, we could leave it like this. > > Reviewed-by: Jonathon Jongsma > ___ > Spice-devel mailing list > Spice-devel@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/spice-devel -- Marc-André Lureau ___ Spice-devel mailing list Spice-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/spice-devel

Re: [Spice-devel] [RFC PATCH spice-protocol v2 04/20] Create a version 2 of the VDAgentMonitorsConfig message

2018-08-22 Thread Marc-André Lureau
isabled > > > + * monitor, this may only be used with agents with the > > > + * VD_AGENT_CAP_SPARSE_MONITORS_CONFIG capability. > > > + */ > > > +uint32_t height; > > > +uint32_t width; > > > +uint32_t depth; > > > +int32_t x; > > > +int32_t y; > > > +} VDAgentMonConfigV2; > > > + > > > +typedef struct SPICE_ATTR_PACKED VDAgentMonitorsConfigV2 { > > > +uint32_t num_of_monitors; > > > +uint32_t flags; > > > +VDAgentMonConfigV2 monitors[0]; > > > +} VDAgentMonitorsConfigV2; > > > + > > > enum { > > > VD_AGENT_DISPLAY_CONFIG_FLAG_DISABLE_WALLPAPER = (1 << 0), > > > VD_AGENT_DISPLAY_CONFIG_FLAG_DISABLE_FONT_SMOOTH = (1 << 1), > ___ > Spice-devel mailing list > Spice-devel@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/spice-devel -- Marc-André Lureau ___ Spice-devel mailing list Spice-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/spice-devel

Re: [Spice-devel] [RFC PATCH v2 00/20] Monitor ID rework

2018-08-21 Thread Marc-André Lureau
Hi On Tue, Aug 21, 2018 at 2:08 PM Lukáš Hrázký wrote: > > On Tue, 2018-08-21 at 13:09 +0200, Marc-André Lureau wrote: > > The API & protocol abstracted away the channel ID/monitor ID details > > for the client. You want to expose it now, but the reasons aren't well

Re: [Spice-devel] [RFC PATCH v2 00/20] Monitor ID rework

2018-08-21 Thread Marc-André Lureau
Hi On Tue, Aug 21, 2018 at 11:44 AM Lukáš Hrázký wrote: > > Well it's a switching point, you need to define it carefully. It may > > be simple or not, but it is just a condition, And the code to switch > > from one to the other shouldn't be so terrible. > > It was also my first idea of a

Re: [Spice-devel] [RFC PATCH v2 00/20] Monitor ID rework

2018-08-21 Thread Marc-André Lureau
on server/agent code, I haven't looked the > > > > > > streaming > > > > > > part. > > > > > > > > > > > > > > > > > > > > > > > > > > > The code is still lacking capabilities to ensure backwards > > > > > > > compatibility, marked with a TODO in a couple of places and > > > > > > > possibly > > > > > > > more is needed. It is meant to work only with all components > > > > > > > having > > > > > > > the > > > > > > > patches from this series. Once this is agreed upon, I'll add > > > > > > > the > > > > > > > capabilities in a later version. > > > > > > > > > > > > > > Some intrusive changes were needed on the client side, > > > > > > > impacting > > > > > > > also > > > > > > > the spice-gtk API. I'd especially like feedback on that, I'm > > > > > > > not > > > > > > > sure > > > > > > > it's good enough as it is. > > > > > > > > > > > > > > One known thing the spice-gtk changes break is the fullscreen > > > > > > > mode > > > > > > > in > > > > > > > virt-viewer. In fullscreen mode, virt-viewer tries to configure > > > > > > > the > > > > > > > monitors as soon as it starts, while now updating the monitors > > > > > > > only > > > > > > > work > > > > > > > after the monitors_config messages were received for them. My > > > > > > > plan > > > > > > > is to > > > > > > > attempt to fix this in virt-viewer, meaning building an older > > > > > > > virt-viewer with spice-gtk containing these changes will result > > > > > > > in > > > > > > > broken fullscreen mode. > > > > > > > > > > > > > > I'll also mention I had some redraw glitches and some gnome- > > > > > > > shell > > > > > > > crashes during testing, which most probably were bugs unrelated > > > > > > > to > > > > > > > SPICE. I decided to get the patches out there and investigate > > > > > > > later, if > > > > > > > you test this and get similar issues though, let me know. > > > > > > > > > > > > > > Cheers, > > > > > > > Lukas > > > > > > > > > Frediano -- Marc-André Lureau ___ Spice-devel mailing list Spice-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/spice-devel

Re: [Spice-devel] [RFC PATCH v2 00/20] Monitor ID rework

2018-08-20 Thread Marc-André Lureau
Hi On Mon, Aug 20, 2018 at 9:00 PM Jonathon Jongsma wrote: > > On Mon, 2018-08-20 at 16:21 +0200, Marc-André Lureau wrote: > > Hi > > > > On Fri, Aug 17, 2018 at 9:48 PM Jonathon Jongsma > > wrote: > > > > > > On Fri, 2018-08-17 at 16:53 +0200,

Re: [Spice-devel] [RFC PATCH v2 00/20] Monitor ID rework

2018-08-20 Thread Marc-André Lureau
Hi On Fri, Aug 17, 2018 at 9:48 PM Jonathon Jongsma wrote: > > On Fri, 2018-08-17 at 16:53 +0200, Marc-André Lureau wrote: > > On Thu, Aug 16, 2018 at 6:26 PM Lukáš Hrázký > > wrote: > > > > > > Hello list, > > > > > > this is the reworked s

Re: [Spice-devel] [PATCH spice] smartcard: set char device state

2018-08-20 Thread Marc-André Lureau
unrelated to this change imho. Please reconsider merging this, it is not changing any current logic, just informing qemu about channel state to avoid useless work. > > Frediano > > > > > ping > > On Tue, Aug 7, 2018 at 5:27 PM wrote: > > > > > > From

Re: [Spice-devel] [PATCH spice] smartcard: set char device state

2018-08-20 Thread Marc-André Lureau
ping On Tue, Aug 7, 2018 at 5:27 PM wrote: > > From: Marc-André Lureau > > Follow all other char devices implementation (spicevmc, agent, > stream-device) and set the char device state when > connected/disconnected. This allows qemu to discard writes, optimize a > b

Re: [Spice-devel] [RFC PATCH v2 00/20] Monitor ID rework

2018-08-17 Thread Marc-André Lureau
sult in > broken fullscreen mode. > > I'll also mention I had some redraw glitches and some gnome-shell > crashes during testing, which most probably were bugs unrelated to > SPICE. I decided to get the patches out there and investigate later, if >

Re: [Spice-devel] [RFC PATCH spice-gtk v2 13/20] Rework the handling of monitors_config

2018-08-17 Thread Marc-André Lureau
c91 100644 > --- a/src/spice-widget.c > +++ b/src/spice-widget.c > @@ -256,7 +256,7 @@ static void update_ready(SpiceDisplay *display) > * application will manage the state of the displays. > */ > if (d->resize_guest_enable) { > -spice_main_channel_updat

Re: [Spice-devel] [cacard v3] tests: Fix 'simpletlv' on i686 arches

2018-08-14 Thread Marc-André Lureau
igned char encoded[] = "\x72\x04\x25\x02\x12\x14"; > static struct simpletlv_member simple[1] = { > -- > 2.17.1 > > ___ > Spice-devel mailing list > Spice-devel@lists.freedesktop.org > https://lists.freedesktop.o

Re: [Spice-devel] [cacard 2/2] tests: Fix 'simpletlv' on i686 arches

2018-08-13 Thread Marc-André Lureau
simpletlv_encode_val(nested, 1, , 0, NULL); > -g_assert_cmpint(result_len, ==, -1); > +g_assert_cmpint((int)result_len, ==, -1); > } > > static void test_encode_skipped(void) > -- > 2.17.1 > > _______ > Spice-devel

Re: [Spice-devel] [cacard 1/2] tests: Add cert.cfg to EXTRA_DIST

2018-08-13 Thread Marc-André Lureau
__ > Spice-devel mailing list > Spice-devel@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/spice-devel -- Marc-André Lureau ___ Spice-devel mailing list Spice-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/spice-devel

Re: [Spice-devel] [PATCH spice-gtk] glib: add SpiceQmpPort helper

2018-08-13 Thread Marc-André Lureau
Hi On Fri, Aug 10, 2018 at 11:26 PM, Victor Toso wrote: > Hi, > > On Fri, Aug 10, 2018 at 03:44:19PM +0200, marcandre.lur...@redhat.com wrote: >> From: Marc-André Lureau >> >> Add a few helper functions to deal with a QMP port channel, in order >> to ease

Re: [Spice-devel] [cacard 4/7] simpletlv: Use g_malloc instead of malloc

2018-08-10 Thread Marc-André Lureau
goto failure; > +tlvp->value.value = g_malloc(vlen); > memcpy(tlvp->value.value, p, vlen); > tlvp->type = SIMPLETLV_TYPE_LEAF; > > -- > 2.17.1 > > ___ > Spice-devel mailing list > Spice-devel@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/spice-devel -- Marc-André Lureau ___ Spice-devel mailing list Spice-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/spice-devel

Re: [Spice-devel] [PATCH libcacard 2/2] vreader: Handle read failure

2018-08-08 Thread Marc-André Lureau
card_free(card); /* free our reference */ > -return VREADER_OK; > +return ret; > } > > struct VReaderListStruct { > -- > 2.17.1 patch looks good to me, ack Jakub, any comment? > > _______ > Spice-devel mailing list >

[Spice-devel] [ANNOUNCE] libcacard 2.6.0 released

2018-08-08 Thread Marc-André Lureau
card/libcacard-2.6.0.tar.xz sha1sum: 4f31cb6954a9e4d542274b5d3b593eeb9547d142 -- Marc-André Lureau ___ Spice-devel mailing list Spice-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/spice-devel

Re: [Spice-devel] [PATCH spice] smartcard: set char device state

2018-08-08 Thread Marc-André Lureau
Hi On Wed, Aug 8, 2018 at 9:42 AM, Frediano Ziglio wrote: >> >> From: Marc-André Lureau >> >> Follow all other char devices implementation (spicevmc, agent, >> stream-device) and set the char device state when >> connected/disconnected. This allows qemu

Re: [Spice-devel] [PATCH libcacard] options: add use_hw=removable

2018-08-06 Thread Marc-André Lureau
Hi On Mon, Aug 6, 2018 at 12:53 PM, Jakub Jelen wrote: > On Fri, 2018-08-03 at 12:40 +0200, marcandre.lur...@redhat.com wrote: >> From: Marc-André Lureau >> >> use_hw=yes is used to specify that libcacard will lookup pkcs11 slots >> that are both removable &

Re: [Spice-devel] [usbredir 2/3] Update references related to Gitlab url

2018-08-03 Thread Marc-André Lureau
otherwise > .SH COPYRIGHT > Copyright 2010-2012 Red Hat, Inc. > License GPLv2+: GNU GPL version 2 or later > <http://gnu.org/licenses/gpl.html>. > -- > 2.17.1 > > _______ > Spice-devel mailing list > Spice-devel@lists.free

Re: [Spice-devel] [PATCH libcacard] options: add use_hw=removable

2018-08-03 Thread Marc-André Lureau
Hi On Fri, Aug 3, 2018 at 12:40 PM, wrote: > From: Marc-André Lureau > > use_hw=yes is used to specify that libcacard will lookup pkcs11 slots > that are both removable & hardware. > > Let's specify that use_hw=removable will select removable slots > (without hardware

Re: [Spice-devel] [PATCH libcacard] options: add use_hw=removable

2018-08-03 Thread Marc-André Lureau
On Fri, Aug 3, 2018 at 12:40 PM, wrote: > From: Marc-André Lureau > > use_hw=yes is used to specify that libcacard will lookup pkcs11 slots > that are both removable & hardware. > > Let's specify that use_hw=removable will select removable slots > (without hardware

Re: [Spice-devel] Implement GSC-IS 2.1 (CAC2) v2 with passing tests

2018-08-02 Thread Marc-André Lureau
in review. hwtests is a bit problematic because it breaks "make check", let see what we can do. > Regards, > Jakub > > > ___ > Spice-devel mailing list > Spice-devel@lists.freedesktop.org > https://l

Re: [Spice-devel] [PATCH libcacard v2 20/35] vcard_emul: New function vcard_emul_read_object()

2018-08-02 Thread Marc-André Lureau
+} > +PK11_DestroyGenericObjects(firstObj); > + > +if (!myObj) > +return NULL; > + > +r = PK11_ReadRawAttribute(PK11_TypeGeneric, myObj, > +CKA_VALUE, ); > +PK11_DestroyGenericObject(myObj); > + if (r

Re: [Spice-devel] [PATCH libcacard v2 02/35] vcard_emul: New function vcard_emul_rsa_bits

2018-08-02 Thread Marc-André Lureau
*/ > vcard_7816_status_t > vcard_emul_rsa_op(VCard *card, VCardKey *key, > -- > 2.17.1 > > ___ > Spice-devel mailing list > Spice-devel@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/spice-devel -- Marc-André Lureau ___ Spice-devel mailing list Spice-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/spice-devel

Re: [Spice-devel] [PATCH libcacard 44/45] Set up the CI in gitlab including coverage reports

2018-08-02 Thread Marc-André Lureau
On Wed, Aug 1, 2018 at 10:00 AM, Jakub Jelen wrote: > On Tue, 2018-07-31 at 18:14 +0200, Marc-André Lureau wrote: >> Hi >> >> On Tue, Jul 31, 2018 at 4:50 PM, Jakub Jelen >> wrote: >> > Signed-off-by: Jakub Jelen >> > Reviewed-by: Robe

Re: [Spice-devel] Implement GSC-IS 2.1 (CAC2)

2018-07-31 Thread Marc-André Lureau
(not at the end of the series) thanks -- Marc-André Lureau ___ Spice-devel mailing list Spice-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/spice-devel

Re: [Spice-devel] [PATCH libcacard 42/45] Add automated way of running tests with softhsm

2018-07-31 Thread Marc-André Lureau
eanup" ]; then > + rm -rf .tokens $CONF $NSSDB > + exit > +fi > + > +# Drop the requirement of HW slot in the libcacard: > +sed -e 's/ || !PK11_IsHW(slot)//g' -i.backup src/vcard_emul_nss.c This is quite a hack too! you could simply introduce an option or an environement variable for testing... If you don't address it now, please add a TODO. > +make check > +RV=$? > +#restore from backup > +mv src/vcard_emul_nss.c{.backup,} > +make > + > +exit $RV > diff --git a/tests/cert.cfg b/tests/cert.cfg > new file mode 100644 > index 000..409aa93 > --- /dev/null > +++ b/tests/cert.cfg > @@ -0,0 +1,6 @@ > +organization = "OpenSC" > +expiration_days = 365 > +email = "n...@example.org" > +signing_key > +encryption_key > + > -- > 2.17.1 > > ___ > Spice-devel mailing list > Spice-devel@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/spice-devel -- Marc-André Lureau ___ Spice-devel mailing list Spice-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/spice-devel

Re: [Spice-devel] [PATCH libcacard 09/45] Adjust PKI Applet to CAC 2

2018-07-31 Thread Marc-André Lureau
/* Clone the properties */ > +applet_private->properties_len = 4; > +applet_private->properties = simpletlv_clone(properties, 4); > +if (applet_private->properties == NULL) > +goto failure; > > pki_applet_data->key = key; > return applet_private; > + > +failure: >

Re: [Spice-devel] [PATCH libcacard 08/45] hex_dump: Helper function to allow inspection of internal buffers

2018-07-31 Thread Marc-André Lureau
Hi On Tue, Jul 31, 2018 at 11:53 PM, Marc-André Lureau wrote: > Hi > > On Tue, Jul 31, 2018 at 4:50 PM, Jakub Jelen wrote: >> Signed-off-by: Jakub Jelen >> Reviewed-by: Robert Relyea > > This isn't used in your tree, let's not add dead code. My bad, the

Re: [Spice-devel] [PATCH libcacard 08/45] hex_dump: Helper function to allow inspection of internal buffers

2018-07-31 Thread Marc-André Lureau
ed char *buf, unsigned short x); > unsigned short lebytes2ushort(const unsigned char *buf); > > +char *hex_dump(unsigned char *, size_t, unsigned char **, size_t); > + > #endif > -- > 2.17.1 > > ___ > Spice-devel mailing list > Spice-devel@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/spice-devel -- Marc-André Lureau ___ Spice-devel mailing list Spice-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/spice-devel

Re: [Spice-devel] [PATCH libcacard 04/45] Basic SimpleTLV encoding and decoding methods

2018-07-31 Thread Marc-André Lureau
gether with V > + * @param tlv array of TLV structures to encode > + * @param tlvlennumber of members in the array to encode > + * @param out Byte array to write into > + * @param outlenThe length of output array > + * @param ptr The end of TLV re

Re: [Spice-devel] [PATCH libcacard 05/45] tests: Cover the SimpleTLV with functional tests

2018-07-31 Thread Marc-André Lureau
sult_len = simpletlv_encode_tl(nested, 1, , 0, NULL); > +g_assert_cmpint(result_len, ==, -1); > + > +/* Encode only VALUE part (equals to the value itself) */ > +result = NULL; > +result_len = simpletlv_encode_val(nested, 1, , 0, NULL); > +g_assert_cmpint(resu

<    1   2   3   4   5   6   7   8   9   10   >