In the file source/blender/editors/sculpt_paint/paint_image_proj.c line 6094 in the function texture_paint_camera_project_exec(...):
ED_image_undo_push_begin(op->type->name, PAINT_MODE_TEXTURE_3D)
is called, but it is not paired with
ED_image_undo_push_end();
this patch adds a call to ED_image_undo_push_end() right before the return OPERATOR_FINISHED;
This seems to work and have no ill side effects, but I'm not sure it is completely correct, as the function can still return with OPERATOR_CANCELLED earlier and I'm not sure if ED_image_undo_push_end() should be called then as well.