Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

treat src warnings as errors

Fix compilation warning in yaws_dav.erl so that no compilation errors
exist in the build, allowing us to treat warnings as errors in
rebar.config and in src/Makefile.
  • Loading branch information...
commit e3f358eb983b4cc7653e79ec264284c942e6d92d 1 parent 62b89d9
@vinoski vinoski authored
View
3  rebar.config
@@ -3,7 +3,8 @@
{erl_opts, [{platform_define,
"(linux|freebsd|darwin)", 'HAVE_SENDFILE'},
- no_debug_info]}.
+ no_debug_info,
+ warnings_as_errors]}.
{port_envs, [{"CFLAGS", "$CFLAGS -g -O3 -Wall -I/usr/include/security"},
{"(linux|freebsd|dragonfly|solaris|darwin)",
View
2  src/Makefile
@@ -60,7 +60,7 @@ MODULES=yaws \
EBIN_FILES=$(MODULES:%=../ebin/%.$(EMULATOR)) ../ebin/yaws.app ../ebin/yaws.appup
-ERLC_FLAGS+=-W $(DEBUG_FLAGS) -pa ../../yaws -I ../include
+ERLC_FLAGS+=-Werror $(DEBUG_FLAGS) -pa ../../yaws -I ../include
#
# Targets
View
4 src/yaws_dav.erl
@@ -60,8 +60,8 @@ put(SC, ARG) ->
ok;
PPS < Int_len, CT == multipart ->
%% FIXME: handle this
- {partial,
- store_client_data(Fd,CliSock, PPS, SSL)};
+ %% {partial,
+ store_client_data(Fd,CliSock, PPS, SSL); % };
true ->
store_client_data(Fd, CliSock, Int_len, SSL)
end;
View
2  src/yaws_server.erl
@@ -993,7 +993,7 @@ acceptor0(GS, Top) ->
%% Don't log SSL esslaccept to error log since it
%% seems this is what we get on portscans and
%% similar
- ?Debug("SSL accept failed: ~p~n", [Reason]),
+ ?Debug("SSL accept failed: ~p~n", [esslaccept]),
Top ! {self(), decrement},
exit(normal);
{error, Reason} ->
Please sign in to comment.
Something went wrong with that request. Please try again.