FBO problem: error 1286

Hi all,
I had a problem using FBO to do some calculations updating a render texture, while using the texture itself as input in the FP using Cg. I used a temp RT texture as the output, and after rendering, copy it back to the original. The code is like the following:

glBindFramebufferEXT( GL_FRAMEBUFFER_EXT, m_fbo );
glFramebufferTexture2DEXT( GL_FRAMEBUFFER_EXT, GL_COLOR_ATTACHMENT0_EXT, GL_TEXTURE_2D, m_writeTo, 0 );

...//render

glBindTexture (GL_TEXTURE_2D, m_writeTo);
glCopyTexSubImage2D(m_copyBackTo, 0, 0, 0, 0, 0, m_width, m_height);
int err = glGetError(); 

Then I got error code 1286, which means frame buffer not complete. So how can I handle this?