aboutsummaryrefslogtreecommitdiff
path: root/cpu-exec.c
diff options
context:
space:
mode:
authorblueswir1 <blueswir1@c046a42c-6fe2-441c-8c8c-71466251a162>2007-12-11 19:35:45 +0000
committerblueswir1 <blueswir1@c046a42c-6fe2-441c-8c8c-71466251a162>2007-12-11 19:35:45 +0000
commitd07bde88a52bf293c3f8846cfd162e0a57e1557c (patch)
tree7208f959405bab8a90da93dd175e2ff5161760ed /cpu-exec.c
parent52df269ca821e8bed49ae2d46fe67486f3ef88de (diff)
Fix code generation buffer overflow reported by TeLeMan
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3805 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'cpu-exec.c')
-rw-r--r--cpu-exec.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/cpu-exec.c b/cpu-exec.c
index 3629cacd7c..c92f1f7d72 100644
--- a/cpu-exec.c
+++ b/cpu-exec.c
@@ -133,7 +133,7 @@ static TranslationBlock *tb_find_slow(target_ulong pc,
tb->tc_ptr = tc_ptr;
tb->cs_base = cs_base;
tb->flags = flags;
- cpu_gen_code(env, tb, CODE_GEN_MAX_SIZE, &code_gen_size);
+ cpu_gen_code(env, tb, &code_gen_size);
code_gen_ptr = (void *)(((unsigned long)code_gen_ptr + code_gen_size + CODE_GEN_ALIGN - 1) & ~(CODE_GEN_ALIGN - 1));
/* check next page if needed */