1. 15 8月, 2018 2 次提交
    • M
      storage: Properly terminate secrets · bfd91dc0
      Michal Privoznik 提交于
      The virSecretGetSecretString() helper looks up a secret for given
      pool and returns its value in @secret_value and its length in
      @secret_value_size. However, the trailing '\0' is not included in
      either of the variables. This is because usually the value of the
      secret is passed to some encoder (usually base64 encoder) where
      the trailing zero must not be accounted for.
      
      However, in two places we actually want the string as we don't
      process it any further.
      Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
      Reviewed-by: NJán Tomko <jtomko@redhat.com>
      bfd91dc0
    • M
      rpc: Initialize a worker pool for max_workers=0 as well · 7330d091
      Marc Hartmayer 提交于
      Semantically, there is no difference between an uninitialized worker
      pool and an initialized worker pool with zero workers. Let's allow the
      worker pool to be initialized for max_workers=0 as well then which
      makes the API more symmetric and simplifies code. Validity of the
      worker pool is delegated to virThreadPoolGetMaxWorkers instead.
      
      This patch fixes segmentation faults in
      virNetServerGetThreadPoolParameters and
      virNetServerSetThreadPoolParameters for the case when no worker pool
      is actually initialized (max_workers=0).
      Signed-off-by: NMarc Hartmayer <mhartmay@linux.ibm.com>
      7330d091
  2. 14 8月, 2018 38 次提交