lib: Fix two nullable annotations
authorColin Walters <walters@verbum.org>
Fri, 17 Mar 2023 12:19:22 +0000 (08:19 -0400)
committerColin Walters <walters@verbum.org>
Fri, 17 Mar 2023 12:25:23 +0000 (08:25 -0400)
- commit parents are optional
- remote URLs are optional

src/libostree/ostree-core.c
src/libostree/ostree-remote.c
src/libostree/ostree-sepolicy.c

index 0d1b0d5d0ca8498e7b4a5cc9d42d58ac84ebb2c7..97888be6273c6ed622d87587f617152e92d10a8a 100644 (file)
@@ -2445,7 +2445,7 @@ ostree_validate_structureof_dirmeta (GVariant      *dirmeta,
  * ostree_commit_get_parent:
  * @commit_variant: Variant of type %OSTREE_OBJECT_TYPE_COMMIT
  *
- * Returns: Checksum of the parent commit of @commit_variant, or %NULL
+ * Returns: (nullable): Checksum of the parent commit of @commit_variant, or %NULL
  * if none
  */
 gchar *
index 04f08352701c3e602ac5c06d68e878ae3d32acac..3695e0f4469cf8d6dd90f93669ed7ae02dcadf06 100644 (file)
@@ -186,7 +186,7 @@ ostree_remote_get_name (OstreeRemote *remote)
  *
  * Get the URL from the remote.
  *
- * Returns: (transfer full): the remote's URL
+ * Returns: (transfer full) (nullable): the remote's URL
  * Since: 2018.6
  */
 gchar *
index 7271bec45ede7a95d5c1586e9f1fae0c1d897ee4..a7795a96fbe8da3e30aeac698d20b4d23d1e76bb 100644 (file)
@@ -502,7 +502,7 @@ ostree_sepolicy_new_at (int         rootfs_dfd,
  * policy objects to be created from file-descriptor relative paths, which
  * may not be globally accessible.
  *
- * Returns: (transfer none): Path to rootfs
+ * Returns: (transfer none) (nullable): Path to rootfs
  */
 GFile *
 ostree_sepolicy_get_path (OstreeSePolicy  *self)
@@ -530,7 +530,7 @@ ostree_sepolicy_get_name (OstreeSePolicy *self)
  * ostree_sepolicy_get_csum:
  * @self:
  *
- * Returns: (transfer none): Checksum of current policy
+ * Returns: (transfer none) (nullable): Checksum of current policy
  *
  * Since: 2016.5
  */