Tss2_TctiLdr_FreeInfo.3.in 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. .\" Process this file with
  2. .\" groff -man -Tascii foo.1
  3. .\"
  4. .TH Tss2_TctiLdr_FreeInfo 3 "JUNE 2019" "TPM2 Software Stack"
  5. .SH NAME
  6. Tss2_TctiLdr_FreeInfo \- Function to free a TSS2_TCTI_INFO structure
  7. allocated by
  8. .BR Tss2_TctiLdr_Initialize ().
  9. .SH SYNOPSIS
  10. .B #include <tss2/tss2_tctildr.h>
  11. .sp
  12. .sp
  13. .BI "void Tss2_TctiLdr_FreeInfo (TSS2_TCTI_INFO" "*info" ");"
  14. .sp
  15. .SH DESCRIPTION
  16. The
  17. .BR Tss2_TctiLdr_FreeInfo ()
  18. function destroys an instance of the TSS2_TCTI_INFO structure created by
  19. the
  20. .BR Tss2_TctiLdr_GetInfo ()
  21. function.
  22. .sp
  23. The
  24. .I info
  25. parameter is a reference to the TSS2_TCTI_INFO structure to be freed.
  26. .sp
  27. .SH RETURN VALUE
  28. This function returns no value.
  29. .SH EXAMPLE
  30. Example code.
  31. .sp
  32. .nf
  33. #include <inttypes.h>
  34. #include <stdlib.h>
  35. #include <stdio.h>
  36. #include <tss2/tss2_tctildr.h>
  37. TSS2_TCTI_INFO *info = NULL;
  38. TSS2_RC rc = Tss2_TctiLdr_GetInfo (NULL, &info);
  39. if (rc != TSS2_RC_SUCCESS) {
  40. fprintf (stderr, "Failed to get TSS2_TCTI_INFO structure for default "
  41. "TCTI with response code: 0x%" PRIx32 "\n", rc);
  42. exit (EXIT_FAILURE);
  43. }
  44. if (info != NULL) {
  45. Tss2_TctiLdr_FreeInfo (info);
  46. info = NULL;
  47. }
  48. exit (EXIT_SUCCESS);
  49. .fi