# PetscSegBufferExtractTo
extract contiguous data to provided buffer and reset segmented buffer 
## Synopsis
```
PetscErrorCode PetscSegBufferExtractTo(PetscSegBuffer seg, void *contig)
```
Not Collective


## Input Parameters

- ***seg -*** segmented buffer
- ***contig -*** allocated buffer to hold contiguous data





## See Also
 `PetscSegBufferCreate()`, `PetscSegBufferGet()`, `PetscSegBufferDestroy()`, `PetscSegBufferExtractAlloc()`, `PetscSegBufferExtractInPlace()`

## Level
developer

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/sys/utils/segbuffer.c.html#PetscSegBufferExtractTo">src/sys/utils/segbuffer.c</A>


---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/sys/utils/segbuffer.c)


[Index of all Sys routines](index.md)  
[Table of Contents for all manual pages](/docs/manualpages/index.md)  
[Index of all manual pages](/docs/manualpages/singleindex.md)  
