---
name: "array_fail"
section: "3diet"
platform: "linux"
package: "libowfat-dev"
version: "0.28-2"
release: "Debian 6.0 (Squeeze)"
platforms: ["linux"]
url: "https://new.carta.tech/array_fail/3diet"
---

# array\_fail(3diet)

switch array to have failed

## NAME

array\_fail - switch array to have failed

## SYNTAX

**#include \<array.h\>**

void **array\_fail**(array\* *x*);

  array *x*;\
   array\_fail(&*x*);

## DESCRIPTION

If *x* is allocated, array\_fail frees the region that *x* points to, and switches *x* to have failed.

If *x* is unallocated, array\_fail simply switches *x* to have failed.

If *x* has already failed, array\_fail has no effect.

## SEE ALSO

[array\_allocate(3)](/array_allocate/3.md), [array\_reset(3)](/array_reset/3.md)
