ivmartel/dwv

View on GitHub

Showing 218 of 386 total issues

Avoid deeply nested control flow statements.
Open

              for (b = 0; b < numBuffers; b++) {
                items[k + b] = colBuffers[b][l];
              }
Severity: Major
Found in decoders/pdfjs/jpx.js - About 45 mins to fix

    Avoid deeply nested control flow statements.
    Open

                for (j = 0; j < v; j++) {
                  for (k = 0; k < h; k++) {
                    decodeMcu(component, decodeFn, mcu, j, k);
                  }
                }
    Severity: Major
    Found in decoders/pdfjs/jpg.js - About 45 mins to fix

      Avoid deeply nested control flow statements.
      Open

                    for (; l < layersCount;) {
                      var packet = createPacket(resolution, k, l);
                      l++;
                      return packet;
                    }
      Severity: Major
      Found in decoders/pdfjs/jpx.js - About 45 mins to fix

        Avoid deeply nested control flow statements.
        Open

                      if (k === null) {
                        continue;
                      }
        Severity: Major
        Found in decoders/pdfjs/jpx.js - About 45 mins to fix

          Avoid deeply nested control flow statements.
          Open

                      for (pos = c, j = 0, jj = items.length; j < jj; j++) {
                        val = items[j];
                        out[pos] = (val + offset);
                        pos += componentsCount;
                      }
          Severity: Major
          Found in decoders/pdfjs/jpx.js - About 45 mins to fix

            Avoid deeply nested control flow statements.
            Open

                                if ((value >> 4) === 0) {
                                    break;
                                }
            Severity: Major
            Found in decoders/rii-mango/lossless.js - About 45 mins to fix

              Avoid deeply nested control flow statements.
              Open

                          for (var l=0; l < layerNumber; l++) {
                            if (readBits(1) !== 0) {
                              throw new Error('JPX Error: Invalid tag tree');
                            }
                          }
              Severity: Major
              Found in decoders/pdfjs/jpx.js - About 45 mins to fix

                Avoid deeply nested control flow statements.
                Open

                            if (sign[position] !== 0) {
                              n = -n;
                            }
                Severity: Major
                Found in decoders/pdfjs/jpx.js - About 45 mins to fix

                  Avoid deeply nested control flow statements.
                  Open

                              while (true) {
                                if (readBits(1)) {
                                  valueReady = !inclusionTree.nextLevel();
                                  if (valueReady) {
                                    codeblock.included = true;
                  Severity: Major
                  Found in decoders/pdfjs/jpx.js - About 45 mins to fix

                    Avoid deeply nested control flow statements.
                    Open

                                  if (k === null) {
                                    continue;
                                  }
                    Severity: Major
                    Found in decoders/pdfjs/jpx.js - About 45 mins to fix

                      Avoid deeply nested control flow statements.
                      Open

                                    for (; l < layersCount;) {
                                      var packet = createPacket(resolution, k, l);
                                      l++;
                                      return packet;
                                    }
                      Severity: Major
                      Found in decoders/pdfjs/jpx.js - About 45 mins to fix

                        Avoid deeply nested control flow statements.
                        Open

                                    for (pos = c, j = 0, jj = items.length; j < jj; j++) {
                                      val = items[j];
                                      out[pos] = val <= min ? 0 :
                                                 val >= max ? 255 : (val + offset) >> shift;
                                      pos += componentsCount;
                        Severity: Major
                        Found in decoders/pdfjs/jpx.js - About 45 mins to fix

                          Avoid deeply nested control flow statements.
                          Open

                                      if(isSigned){
                                        shift = 0;
                                        offset = 0;
                                      }else{
                                        shift = components[c].precision - 8;
                          Severity: Major
                          Found in decoders/pdfjs/jpx.js - About 45 mins to fix

                            Avoid deeply nested control flow statements.
                            Open

                                            for (j = 0; j < 64; j++) {
                                              z = dctZigZag[j];
                                              tableData[z] = data[offset++];
                                            }
                            Severity: Major
                            Found in decoders/pdfjs/jpg.js - About 45 mins to fix

                              Function generateImageDataMonochrome has 5 arguments (exceeds 4 allowed). Consider refactoring.
                              Open

                                array,
                                iterator,
                                alphaFunc,
                                windowLut,
                                colourMap) {
                              Severity: Minor
                              Found in src/image/viewMonochrome.js - About 35 mins to fix

                                Function getPrecinctIndexIfExist has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                Open

                                    pxIndex, pyIndex, sizeInImageScale, precinctIterationSizes, resolution) {
                                Severity: Minor
                                Found in decoders/pdfjs/jpx.js - About 35 mins to fix

                                  Function simpleRange3d has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                  Open

                                    dataAccessor, start, end, increment, isPlanar) {
                                  Severity: Minor
                                  Found in src/image/iterator.js - About 35 mins to fix

                                    Function BitModel has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                    Open

                                        function BitModel(width, height, subband, zeroBitPlanes, mb) {
                                    Severity: Minor
                                    Found in decoders/pdfjs/jpx.js - About 35 mins to fix

                                      Function generateImageDataPaletteColor has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                      Open

                                        array,
                                        iterator,
                                        alphaFunc,
                                        colourMap,
                                        is16BitsStored) {
                                      Severity: Minor
                                      Found in src/image/viewPaletteColor.js - About 35 mins to fix

                                        Function rangeRegions has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                        Open

                                          dataAccessor, start, end, increment, regions) {
                                        Severity: Minor
                                        Found in src/image/iterator.js - About 35 mins to fix
                                          Severity
                                          Category
                                          Status
                                          Source
                                          Language