Skip to content

Most visited

Recently visited


sync.h File Reference

sync.h File Reference


__BEGIN_DECLS int32_t sync_merge (const char *name, int32_t fd1, int32_t fd2)
struct sync_file_info * sync_file_info (int32_t fd)
void sync_file_info_free (struct sync_file_info *info)

Function Documentation

◆ sync_file_info()

struct sync_file_info* sync_file_info ( int32_t  fd)

Retrieve detailed information about a sync file and its fences.

The returned sync_file_info must be freed by calling sync_file_info_free().

◆ sync_file_info_free()

void sync_file_info_free ( struct sync_file_info info)

Free a struct sync_file_info structure

◆ sync_merge()

__BEGIN_DECLS int32_t sync_merge ( const char *  name,
int32_t  fd1,
int32_t  fd2 

Merge two sync files.

This produces a new sync file with the given name which has the union of the two original sync file's fences; redundant fences may be removed.

If one of the input sync files is signaled or invalid, then this function may behave like dup(): the new file descriptor refers to the valid/unsignaled sync file with its original name, rather than a new sync file.

The original fences remain valid, and the caller is responsible for closing them.

This site uses cookies to store your preferences for site-specific language and display options.

Get the latest Android developer news and tips that will help you find success on Google Play.

* Required Fields


Follow Google Developers on WeChat

Browse this site in ?

You requested a page in , but your language preference for this site is .

Would you like to change your language preference and browse this site in ? If you want to change your language preference later, use the language menu at the bottom of each page.

This class requires API level or higher

This doc is hidden because your selected API level for the documentation is . You can change the documentation API level with the selector above the left navigation.

For more information about specifying the API level your app requires, read Supporting Different Platform Versions.

Take a short survey?
Help us improve the Android developer experience. (April 2018 — Developer Survey)