ObjFW  Diff

Differences From Artifact [06ca9c602c]:

To Artifact [85bf245254]:


161
162
163
164
165
166
167










168
169
170
171
172
173
174
				  encoding: [OFLocalization encoding]];
#else
	char buffer[PATH_MAX];

	if ((getcwd(buffer, PATH_MAX)) == NULL)
		@throw [OFGetCurrentDirectoryPathFailedException
		    exceptionWithErrNo: errno];











	return [OFString stringWithCString: buffer
				  encoding: [OFLocalization encoding]];
#endif
}

- (OFURL *)currentDirectoryURL







>
>
>
>
>
>
>
>
>
>







161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
				  encoding: [OFLocalization encoding]];
#else
	char buffer[PATH_MAX];

	if ((getcwd(buffer, PATH_MAX)) == NULL)
		@throw [OFGetCurrentDirectoryPathFailedException
		    exceptionWithErrNo: errno];

# ifdef OF_DJGPP
	/*
	 * For some reason, getcwd() returns forward slashes on DJGPP, even
	 * though the native format is to use backwards slashes.
	 */
	for (char *tmp = buffer; *tmp != '\0'; tmp++)
		if (*tmp == '/')
			*tmp = '\\';
# endif

	return [OFString stringWithCString: buffer
				  encoding: [OFLocalization encoding]];
#endif
}

- (OFURL *)currentDirectoryURL