FwupdPlugin.bytes_align
Description: Reference for FwupdPlugin.bytes_align

### Function

# FwupdPluginbytes_align

since: 1.8.2

#### Declaration [src]

    GBytes*
    fu_bytes_align (
      GBytes* bytes,
      gsize blksz,
      gchar padval
    )

#### Description [src]

Aligns a block of memory to `blksize` using the `padval` value; if the block is already aligned then the original `bytes` is returned.

Available since: 1.8.2

#### Parameters

`bytes`

  Type: `GBytes`

  Data blob.

  The data is owned by the caller of the function.

`blksz`

  Type: `gsize`

  Block size in bytes.

`padval`

  Type: `gchar`

  The byte used to pad the byte buffer.

#### Return value

Type: `GBytes`

A `GBytes`, possibly `bytes`.

The caller of the function takes ownership of the data, and is responsible for freeing it.