~ubuntu-branches/ubuntu/oneiric/audacious-plugins/oneiric

« back to all changes in this revision

Viewing changes to src/neon/rb.c

  • Committer: Bazaar Package Importer
  • Author(s): Benjamin Drung
  • Date: 2010-04-13 22:48:07 UTC
  • mfrom: (1.1.12 upstream) (2.1.5 experimental)
  • Revision ID: james.westby@ubuntu.com-20100413224807-imw9qnn26cxcgefq
Tags: 2.3-1ubuntu1
* Merge from Debian experimental (LP: #494604), remaining change:
  - audacious-plugins suggests timidiy for midi playback
* Build-Depend on libav* for ffaudio.
* Break and replace audacious (<< 2.3).
* Drop audacious-plugins-dev package. "apt-get build-dep audacious-plugins"
  will do the same job.
* audacious-plugins recommends audacious instead of depending on it to break
  the circular dependency (Closes: #528588).

Show diffs side-by-side

added added

removed removed

Lines of Context:
106
106
    _LEAVE;
107
107
}
108
108
 
109
 
/* 
 
109
/*
110
110
 * Initialize a ringbuffer structure (including
111
111
 * memory allocation.
112
112
 *
148
148
    _LEAVE 0;
149
149
}
150
150
 
151
 
/* 
 
151
/*
152
152
 * Initialize a ringbuffer structure (including
153
153
 * memory allocation.
154
154
 * The mutex to be used is passed in the function call.
205
205
         * one piece. We need to split the copy into two parts.
206
206
         */
207
207
        memcpy(rb->wp, buf, endfree);
208
 
        memcpy(rb->buf, buf+endfree, size-endfree);
 
208
        memcpy(rb->buf, (char *) buf + endfree, size - endfree);
209
209
        rb->wp = rb->buf + (size-endfree);
210
210
    } else if (endfree > size) {
211
211
        /*
292
292
             * There is enough data in the buffer, but it is fragmented.
293
293
             */
294
294
            memcpy(buf, rb->rp, endused);
295
 
            memcpy(buf+endused, rb->buf, size-endused);
 
295
            memcpy((char *) buf + endused, rb->buf, size - endused);
296
296
            rb->rp = rb->buf + (size-endused);
297
297
        }
298
298
    }