#vulnerable code 
                                public static void start(Class<?> clazz,String path) throws Exception {

        long start = System.currentTimeMillis();


        //init application
        AppConfig.getInstance().setRootPackageName(clazz.getPackage().getName());
        AppConfig.getInstance().setRootPath(path);

        InputStream resourceAsStream = CicadaServer.class.getClassLoader().getResourceAsStream("application.properties");
        Properties prop = new Properties();
        prop.load(resourceAsStream);
        int port = Integer.parseInt(prop.get(CicadaConstant.CICADA_PORT).toString());

        AppConfig.getInstance().setPort(port);

        List<Class<?>> configuration = ClassScanner.getConfiguration(AppConfig.getInstance().getRootPackageName());
        for (Class<?> aClass : configuration) {
            AbstractCicadaConfiguration conf = (AbstractCicadaConfiguration) aClass.newInstance() ;
            InputStream stream = CicadaServer.class.getClassLoader().getResourceAsStream(conf.getPropertiesName());
            Properties properties = new Properties();
            properties.load(stream);
            conf.setProperties(properties) ;

            ConfigurationHolder.addConfiguration(aClass.getName(),conf) ;
        }

        try {
            ServerBootstrap bootstrap = new ServerBootstrap()
                    .group(boss, work)
                    .channel(NioServerSocketChannel.class)
                    .childHandler(new CicadaInitializer());

            ChannelFuture future = bootstrap.bind(port).sync();
            if (future.isSuccess()) {
                long end = System.currentTimeMillis();
                LOGGER.info("Cicada started on port: {}.cost {}ms", port ,end-start);
            }
            Channel channel = future.channel();
            channel.closeFuture().sync();

        } finally {
            boss.shutdownGracefully();
            work.shutdownGracefully();
        }
    } 
                            #location 18 
                            #vulnerability type NULL_DEREFERENCE
#fixed code
                                public static void start(Class<?> clazz,String path) throws Exception {
        InitSetting.setting(clazz,path) ;
        NettyBootStrap.startServer();
    }