aboutsummaryrefslogtreecommitdiff
path: root/src/libui_sdl/libui/darwin/text.m
blob: f0d3dab69e75700363910ceacbe6c73c7ed81ab9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
// 10 april 2015
#import "uipriv_darwin.h"

char *uiDarwinNSStringToText(NSString *s)
{
	char *out;

	out = strdup([s UTF8String]);
	if (out == NULL) {
		fprintf(stderr, "memory exhausted in uiDarwinNSStringToText()\n");
		abort();
	}
	return out;
}

void uiFreeText(char *s)
{
	free(s);
}