diff options
author | Eric Blake <eblake@redhat.com> | 2019-11-13 20:46:32 -0600 |
---|---|---|
committer | Eric Blake <eblake@redhat.com> | 2019-11-18 16:01:34 -0600 |
commit | 9d7ab222da5a9de61b34f26ec442d37ccdd18cf0 (patch) | |
tree | 3e9909533221eb61a13776d70b21ab0c05dc72f8 /nbd/trace-events | |
parent | f61ffad53f6d1cc4e23c557e22ed3d4f0ad0ae5e (diff) |
nbd/server: Prefer heap over stack for parsing client names
As long as we limit NBD names to 256 bytes (the bare minimum permitted
by the standard), stack-allocation works for parsing a name received
from the client. But as mentioned in a comment, we eventually want to
permit up to the 4k maximum of the NBD standard, which is too large
for stack allocation; so switch everything in the server to use heap
allocation. For now, there is no change in actually supported name
length.
Signed-off-by: Eric Blake <eblake@redhat.com>
Message-Id: <20191114024635.11363-2-eblake@redhat.com>
[eblake: fix uninit variable compile failure]
Reviewed-by: Maxim Levitsky <mlevitsk@redhat.com>
Reviewed-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Diffstat (limited to 'nbd/trace-events')
0 files changed, 0 insertions, 0 deletions