compensate roll and pitch when yaw change

Hi there, i have a probleme about reading values from imu gy87 "acc,gyro,magnet and baro" i'm using this cool library from i2cdevlib/Arduino/MPU6050 at master · jrowberg/i2cdevlib · GitHub.
the only problem i got is when i do a yaw the value of roll and pitch change values even i am in a flat ground.
for example when the quadcopter not turning the valu of pitch and roll equal 0 but when i do i yaw the roll and the pitch valu equal 1 or -1.
please how do i compensate that

You've been around long enough to know you're going to have to provide some details before anyone can come up with any answer.