diff options
| author | Nikos Mavrogiannopoulos <nmav@gnutls.org> | 2010-06-17 21:29:51 +0200 |
|---|---|---|
| committer | Nikos Mavrogiannopoulos <nmav@gnutls.org> | 2010-06-17 21:29:51 +0200 |
| commit | cc991ff936e519c21f6d82dc9030caf1340416e4 (patch) | |
| tree | 0d695669912965ca39c99210d8d46a8118e95986 /examples | |
| parent | a3ae7330ecc0b8796945536771e20d586a51987d (diff) | |
| download | cryptodev-linux-cc991ff936e519c21f6d82dc9030caf1340416e4.tar.gz cryptodev-linux-cc991ff936e519c21f6d82dc9030caf1340416e4.tar.xz cryptodev-linux-cc991ff936e519c21f6d82dc9030caf1340416e4.zip | |
Several fixes related to checks with copy_from/to_user.
Diffstat (limited to 'examples')
| -rw-r--r-- | examples/new.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/examples/new.c b/examples/new.c index 72f1517..3cfc206 100644 --- a/examples/new.c +++ b/examples/new.c @@ -673,10 +673,6 @@ test_ncr_store_wrap_key(int cfd) } /* now export the unwrapped */ - /* this cannot be performed like that, because unwrap - * always sets keys as unexportable. Maybe we can implement - * a data comparison ioctl(). - */ memset(&keydata, 0, sizeof(keydata)); keydata.key = key2; keydata.data = dd; @@ -687,6 +683,7 @@ test_ncr_store_wrap_key(int cfd) return 1; } + kdata.data = data; if (ioctl(cfd, NCRIO_DATA_GET, &kdata)) { fprintf(stderr, "Error: %s:%d\n", __func__, __LINE__); perror("ioctl(NCRIO_DATA_GET)"); |
