summaryrefslogtreecommitdiff
path: root/src/heretic/r_plane.c
diff options
context:
space:
mode:
authorSimon Howard2008-09-26 16:25:24 +0000
committerSimon Howard2008-09-26 16:25:24 +0000
commit717ca7f67c77b09c9fc6f36936fbc6bdc4ff8e98 (patch)
tree06c0f946caa74c724ecb3f90e43af7ab049f009e /src/heretic/r_plane.c
parent2fb5056878a2d5a29d8bb9597e2f458b46862ddd (diff)
downloadchocolate-doom-717ca7f67c77b09c9fc6f36936fbc6bdc4ff8e98.tar.gz
chocolate-doom-717ca7f67c77b09c9fc6f36936fbc6bdc4ff8e98.tar.bz2
chocolate-doom-717ca7f67c77b09c9fc6f36936fbc6bdc4ff8e98.zip
Fix up Heretic code for mmaped WAD I/O. Call W_ReleaseLump* instead of
Z_Free/Z_ChangeTag. Subversion-branch: /branches/raven-branch Subversion-revision: 1288
Diffstat (limited to 'src/heretic/r_plane.c')
-rw-r--r--src/heretic/r_plane.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/heretic/r_plane.c b/src/heretic/r_plane.c
index 28c109a4..8c56dad5 100644
--- a/src/heretic/r_plane.c
+++ b/src/heretic/r_plane.c
@@ -379,6 +379,7 @@ void R_DrawPlanes(void)
visplane_t *pl;
int light;
int x, stop;
+ int lumpnum;
int angle;
byte *tempSource;
@@ -454,8 +455,9 @@ void R_DrawPlanes(void)
//
// regular flat
//
- tempSource = W_CacheLumpNum(firstflat +
- flattranslation[pl->picnum], PU_STATIC);
+ lumpnum = firstflat + flattranslation[pl->picnum];
+
+ tempSource = W_CacheLumpNum(lumpnum, PU_STATIC);
switch (pl->special)
{
@@ -512,6 +514,6 @@ void R_DrawPlanes(void)
R_MakeSpans(x, pl->top[x - 1], pl->bottom[x - 1], pl->top[x],
pl->bottom[x]);
- Z_ChangeTag(tempSource, PU_CACHE);
+ W_ReleaseLumpNum(lumpnum);
}
}