Is there a way to create a stream from a string? I know there is a way to do it using gnu's c library but I would rather not depend on that.