Fix wrong #endif comment that does not match the #ifdef directive.
[mplayer/greg.git] / osdep / swab.c
blob46da22c744221a8b32f2207f7a53c20d6ec3948b
1 #include "config.h"
3 /* system has no swab. emulate via bswap */
4 #include "mpbswap.h"
5 #include <unistd.h>
7 void swab(const void *from, void *to, ssize_t n) {
8 const int16_t *in = (int16_t*)from;
9 int16_t *out = (int16_t*)to;
10 int i;
11 n /= 2;
12 for (i = 0 ; i < n; i++) {
13 out[i] = bswap_16(in[i]);