Beispiel #1
0
        handle open(const char* file_, const char* mode, error_policy ep)
        {
#ifdef OX_DEBUG
            if (!strstr(mode, "b"))
                log::warning("file::open for file '%s' should be called with 'b' (means binary) flag", file_);
#endif
            //OX_ASSERT(_openedFiles == 0);
            LOGD("open file: %s %s %d", file_, mode, _openedFiles);
            char file[512];
            path::normalize(file_, file);
            LOGD("q1");


            fileHandle* fh = 0;
            _nfs.open(file, mode, ep_ignore_error, fh);

            LOGD("q3");

            if (!fh)
            {
                handleErrorPolicy(ep, "can't open file: %s", file);
            }

            return (handle)fh;
        }
Beispiel #2
0
		handle open(const char *file_, const char *mode, error_policy ep)
		{
			//OX_ASSERT(_openedFiles == 0);
			LOGD("open file: %s %s %d", file_, mode, _openedFiles);
			char file[512];
			path::normalize(file_, file);
			LOGD("q1");


			fileHandle *fh = 0;
			_nfs.open(file, mode, ep_ignore_error, fh);

			LOGD("q3");

			if (!fh)
			{
				handleErrorPolicy(ep, "can't open file: %s", file);
			}

			return fh;
		}