lkml.org 
[lkml]   [2003]   [Jun]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    Date
    From
    SubjectRe: Misc 2.5 Fixes: cp-user-awe


    Fix copy/user in awe_wave.


    sound/oss/awe_wave.c | 4 ++--
    1 files changed, 2 insertions(+), 2 deletions(-)

    diff -puN sound/oss/awe_wave.c~cp-user-awe sound/oss/awe_wave.c
    --- linux-2.5.70-ds/sound/oss/awe_wave.c~cp-user-awe 2003-06-08 20:49:13.000000000 +0530
    +++ linux-2.5.70-ds-dipankar/sound/oss/awe_wave.c 2003-06-08 20:49:13.000000000 +0530
    @@ -2046,9 +2046,9 @@ awe_ioctl(int dev, unsigned int cmd, cad
    awe_info.nr_voices = awe_max_voices;
    else
    awe_info.nr_voices = AWE_MAX_CHANNELS;
    - memcpy((char*)arg, &awe_info, sizeof(awe_info));
    + if(copy_to_user(arg, &awe_info, sizeof(awe_info)))
    + return -EFAULT;
    return 0;
    - break;

    case SNDCTL_SEQ_RESETSAMPLES:
    awe_reset(dev);
    _
    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/

    \
     
     \ /
      Last update: 2005-03-22 13:36    [W:0.022 / U:0.028 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site