My iOS app uses Cocoapods to manage libraries such as AFNetworking, SDWebImage etc.

One of this library happens to have a bug that's been fixed in the bleeding edge version but it has not been propagated to the cocoapods version yet. I'd like to make a patch for this library and be able to share it with my team. What's the recommended way to deal with this?

On a side note: I'd imagine it might come a time where a similar situation could happen where I will want to fork a library. It would be nice if I then had a way to merge my changes into new versions as the library gets updated. Could a similar workflow be used in that case?

Edit
Report