Skip to content
  • Manuel Stoeckl's avatar
    Implement simple buffer ownership system · f73e15a0
    Manuel Stoeckl authored
    Every wp_object has a nullable reference to the shadow structure
    for a file descriptor. As the existence of wayland protocol
    objects is not guaranteed in the face of compositor/application
    misbehavior, when e.g. a wl_buffer is created from a wl_shm_pool,
    the wl_buffer registers a reference to the file descriptor that
    the wl_shm_pool had. Methods that imply a file descriptor change
    (wl_keyboard.keymap, wl_surface.commit) mark the object's referenced
    file descriptor as dirty, so that changes can be transferred.
    
    This commit does not yet implement any deletion logic.
    f73e15a0